Jefferson-tan / ffmpeg-accel-script

An interactive bash script which detects and uses GPU to accelerate FFmpeg transcoding
GNU Lesser General Public License v3.0
1 stars 0 forks source link

HEVC fallback broken for Intel iGPU #2

Open Jefferson-tan opened 5 months ago

Jefferson-tan commented 5 months ago

Transcoding with hevc on systems with hybrid graphics (Nvida + Intel iGPU) seems to be broken ATM, seems like it's still trying to use Nvidia even though it should fallback to using Intel after failing the first time.

libva info: VA-API version 1.20.0
libva info: User environment variable requested driver 'nvidia'
libva info: Trying to open /usr/lib64/dri/nvidia_drv_video.so
libva info: Found init function __vaDriverInit_1_0
libva error: /usr/lib64/dri/nvidia_drv_video.so init failed
libva info: va_openDriver() returns 1
[hevc_mp4toannexb @ 0x55e717c4c700] Invalid NAL unit type in extradata: 0
[vist#0:0/hevc @ 0x55e717badfc0] Error while opening decoder: Invalid data found when processing input
[vost#0:0/hevc_qsv @ 0x55e717c79fc0] Error initializing a simple filtergraph
Error opening output file /home/richt/Videos/banding.mp4.
Error opening output files: Invalid data found when processing input
Exit code: 183
Jefferson-tan commented 5 months ago

Saying "yes" spits out this exit code instead

Oh no! Nvidia transcoding failed! Do you want to try again with Intel QSV? yes

[AVHWDeviceContext @ 0x55cfd50dec00] libva: /usr/lib64/dri/nvidia_drv_video.so init failed
[AVHWDeviceContext @ 0x55cfd50dec00] Failed to initialise VAAPI connection: 1 (operation failed).
Device creation failed: -5.
Failed to set value '/dev/dri/renderD128' for option 'vaapi_device': Input/output error
Error parsing global options: Input/output error
Exit code: 251
Oh no! Nvidia transcoding failed! Do you want to try again with Intel QSV? yes