[Cin] System ffmpeg Vulkan video transcoding fails - while benchmarking works

Andrea paz gamberucci.andrea at gmail.com
Sat Apr 26 21:37:52 CEST 2025


My test (with another video):

$ ffmpeg -init_hw_device vulkan=vk:0 -filter_hw_device vk -hwaccel
vaapi -hwaccel_output_format vaapi -i hdr_02.mp4
-vf libplacebo=colorspace=bt709:color_primaries=bt709:color_trc=bt709:range=tv
-c:a copy -c:v hevc_vulkan -f avi  /dev/null

[...]
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'hdr_02.mp4':
 Metadata:
   major_brand     : isom
   minor_version   : 512
   compatible_brands: isomiso2mp41
   creation_time   : 2017-06-04T23:05:26.000000Z
   encoder         : Lavf57.72.101
 Duration: 00:02:38.56, start: 0.000000, bitrate: 60142 kb/s
 Stream #0:0[0x1](und): Video: hevc (Main 10) (hev1 / 0x31766568),
yuv420p10le(tv, bt2020nc/bt2020/smpte2084), 3840x2160 [SAR 1:1 DA
R 16:9], 60000 kb/s, 59.94 fps, 59.94 tbr, 90k tbn (default)
     Metadata:
       creation_time   : 2017-06-04T23:05:26.000000Z
       handler_name    : VideoHandler
       vendor_id       : [0][0][0][0]
 Stream #0:1[0x2](und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz,
stereo, fltp, 125 kb/s (default)
     Metadata:
       creation_time   : 2017-06-04T23:05:26.000000Z
       handler_name    : SoundHandler
       vendor_id       : [0][0][0][0]
File '/dev/null' already exists. Overwrite? [y/N] y
Stream mapping:
 Stream #0:0 -> #0:0 (hevc (native) -> hevc (hevc_vulkan))
 Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
[AVHWFramesContext @ 0x7904d401aac0] Unsupported pixel format: vaapi!
[Parsed_libplacebo_0 @ 0x7904d4004600] Failed to configure output pad
on Parsed_libplacebo_0
[vf#0:0 @ 0x5cc205a12800] Error reinitializing filters!
[vf#0:0 @ 0x5cc205a12800] Task finished with error code: -22 (Invalid argument)
[vf#0:0 @ 0x5cc205a12800] Terminating thread with return code -22
(Invalid argument)
[vost#0:0/hevc_vulkan @ 0x5cc205a3b0c0] Could not open encoder before EOF
[vost#0:0/hevc_vulkan @ 0x5cc205a3b0c0] Task finished with error code:
-22 (Invalid argument)
[vost#0:0/hevc_vulkan @ 0x5cc205a3b0c0] Terminating thread with return
code -22 (Invalid argument)
[out#0/avi @ 0x5cc205938c80] Nothing was written into output file,
because at least one of its streams received no packets.
frame=    0 fps=0.0 q=0.0 Lsize=       0KiB time=N/A bitrate=N/A speed=N/A
Conversion failed!


More information about the Cin mailing list