Jellyfin Forum
SOLVED: Hardware acceleration - cannot get it to work - Printable Version

+- Jellyfin Forum (https://forum.jellyfin.org)
+-- Forum: Support (https://forum.jellyfin.org/f-support)
+--- Forum: Troubleshooting (https://forum.jellyfin.org/f-troubleshooting)
+--- Thread: SOLVED: Hardware acceleration - cannot get it to work (/t-solved-hardware-acceleration-cannot-get-it-to-work)



Hardware acceleration - cannot get it to work - performation - 2024-10-25

Hello,
I just upgraded to an Intel 12600k for faster transcoding. I followed the tutorial and installed everything, enabled QSV but nothing plays. I have now spent the past 1.5 days on trying to debug this but I have still not the slightest clue what could be the issue. Any idea would be greatly appreciated.
I am running Jellyfin inside a docker container (rootless) on an Arch VM, playback without hardware acceleration works normally.

FFmpeg log:
Code:
Stream mapping:
  Stream #0:0 -> #0:0 (hevc (native) -> av1 (av1_qsv))
  Stream #0:1 -> #0:1 (eac3 (native) -> aac (libfdk_aac))
Press [q] to stop, [?] for help
libva info: VA-API version 1.22.0
libva info: Trying to open /usr/lib/jellyfin-ffmpeg/lib/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_22
libva info: va_openDriver() returns 0
libva info: VA-API version 1.22.0
libva info: Trying to open /usr/lib/jellyfin-ffmpeg/lib/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_22
libva info: va_openDriver() returns 0
[av1_qsv @ 0x5c8e0a80af80] Current profile is unsupported
[av1_qsv @ 0x5c8e0a80af80] Selected ratecontrol mode is unsupported
[av1_qsv @ 0x5c8e0a80af80] Current frame rate is unsupported
[av1_qsv @ 0x5c8e0a80af80] Current picture structure is unsupported
[av1_qsv @ 0x5c8e0a80af80] Current resolution is unsupported
[av1_qsv @ 0x5c8e0a80af80] Current pixel format is unsupported
[av1_qsv @ 0x5c8e0a80af80] some encoding parameters are not supported by the QSV runtime. Please double check the input parameters.
[vost#0:0/av1_qsv @ 0x5c8e0a818ac0] Error initializing output stream: Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height




Output from docker exec -it jellyfin /usr/lib/jellyfin-ffmpeg/vainfo:
Code:
[/font]
[font=monospace]Trying display: drm [/font]
[font=monospace]libva info: VA-API version 1.22.0 [/font]
[font=monospace]libva info: Trying to open /usr/lib/jellyfin-ffmpeg/lib/dri/iHD_drv_video.so [/font]
[font=monospace]libva info: Found init function __vaDriverInit_1_22 [/font]
[font=monospace]libva info: va_openDriver() returns 0 [/font]
[font=monospace]vainfo: VA-API version: 1.22 (libva 2.22.0) [/font]
[font=monospace]vainfo: Driver version: Intel iHD driver for Intel(R) Gen Graphics - 24.2.5 (12561f6) [/font]
[font=monospace]vainfo: Supported profile and entrypoints [/font]
[font=monospace]     VAProfileNone                   : VAEntrypointVideoProc [/font]
[font=monospace]     VAProfileNone                   : VAEntrypointStats [/font]
[font=monospace]     VAProfileMPEG2Simple            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileMPEG2Simple            : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileMPEG2Main              : VAEntrypointVLD [/font]
[font=monospace]     VAProfileMPEG2Main              : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileH264Main               : VAEntrypointVLD [/font]
[font=monospace]     VAProfileH264Main               : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileH264Main               : VAEntrypointFEI [/font]
[font=monospace]     VAProfileH264Main               : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileH264High               : VAEntrypointVLD [/font]
[font=monospace]     VAProfileH264High               : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileH264High               : VAEntrypointFEI [/font]
[font=monospace]     VAProfileH264High               : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileVC1Simple              : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVC1Main                : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVC1Advanced            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileJPEGBaseline           : VAEntrypointVLD [/font]
[font=monospace]     VAProfileJPEGBaseline           : VAEntrypointEncPicture [/font]
[font=monospace]     VAProfileH264ConstrainedBaseline: VAEntrypointVLD [/font]
[font=monospace]     VAProfileH264ConstrainedBaseline: VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileH264ConstrainedBaseline: VAEntrypointFEI [/font]
[font=monospace]     VAProfileH264ConstrainedBaseline: VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCMain               : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain               : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileHEVCMain               : VAEntrypointFEI [/font]
[font=monospace]     VAProfileHEVCMain               : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCMain10             : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain10             : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileHEVCMain10             : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileVP9Profile0            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVP9Profile0            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileVP9Profile1            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVP9Profile1            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileVP9Profile2            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVP9Profile2            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileVP9Profile3            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileVP9Profile3            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCMain12             : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain12             : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileHEVCMain422_10         : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain422_10         : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileHEVCMain422_12         : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain422_12         : VAEntrypointEncSlice [/font]
[font=monospace]     VAProfileHEVCMain444            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain444            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCMain444_10         : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCMain444_10         : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCMain444_12         : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain            : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCSccMain10          : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain10          : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileHEVCSccMain444         : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain444         : VAEntrypointEncSliceLP [/font]
[font=monospace]     VAProfileAV1Profile0            : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain444_10      : VAEntrypointVLD [/font]
[font=monospace]     VAProfileHEVCSccMain444_10      : VAEntrypointEncSliceLP


Output from docker exec -it jellyfin /usr/lib/jellyfin-ffmpeg/ffmpeg -v verbose -init_hw_device vaapi=va -init_hw_device opencl@va
Code:
[color=#000000]ffmpeg version 6.0.1-Jellyfin Copyright (c) 2000-2023 the FFmpeg developers [/color]
[/font]
[font=monospace] built with gcc 12 (Debian 12.2.0-14) [/font]
[font=monospace] configuration: --prefix=/usr/lib/jellyfin-ffmpeg --target-os=linux --extra-version=Jellyfin --disable-doc --disable-ffplay --disable-ptx-compression --disable-static --disable-libxcb --d[/font]
[font=monospace]isable-sdl2 --disable-xlib --enable-lto --enable-gpl --enable-version3 --enable-shared --enable-gmp --enable-gnutls --enable-chromaprint --enable-opencl --enable-libdrm --enable-libxml2 --[/font]
[font=monospace]enable-libass --enable-libfreetype --enable-libfribidi --enable-libfontconfig --enable-libbluray --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libopen[/font]
[font=monospace]mpt --enable-libdav1d --enable-libsvtav1 --enable-libwebp --enable-libvpx --enable-libx264 --enable-libx265 --enable-libzvbi --enable-libzimg --enable-libfdk-aac --arch=amd64 --enable-libs[/font]
[font=monospace]haderc --enable-libplacebo --enable-vulkan --enable-vaapi --enable-amf --enable-libvpl --enable-ffnvcodec --enable-cuda --enable-cuda-llvm --enable-cuvid --enable-nvdec --enable-nvenc [/font]
[font=monospace] libavutil      58.  2.100 / 58.  2.100 [/font]
[font=monospace] libavcodec     60.  3.100 / 60.  3.100 [/font]
[font=monospace] libavformat    60.  3.100 / 60.  3.100 [/font]
[font=monospace] libavdevice    60.  1.100 / 60.  1.100 [/font]
[font=monospace] libavfilter     9.  3.100 /  9.  3.100 [/font]
[font=monospace] libswscale      7.  1.100 /  7.  1.100 [/font]
[font=monospace] libswresample   4. 10.100 /  4. 10.100 [/font]
[font=monospace] libpostproc    57.  1.100 / 57.  1.100 [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]Trying to use DRM render node for device 0.[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]libva: VA-API version 1.22.0[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]libva: Trying to open /usr/lib/jellyfin-ffmpeg/lib/dri/iHD_drv_video.so[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]libva: Found init function __vaDriverInit_1_22[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]libva: va_openDriver() returns 0[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]Initialised VAAPI connection: version 1.22[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]VAAPI driver: Intel iHD driver for Intel(R) Gen Graphics - 24.2.5 (12561f6).[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca1995f00] [color=#18b218]Driver not found in known nonstandard list, using standard behaviour.[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca19d05c0] [color=#18b218]0.0: Intel(R) OpenCL Graphics / Intel(R) UHD Graphics 770[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca19d05c0] [color=#18b218]Intel QSV to OpenCL mapping function found (clCreateFromVA_APIMediaSurfaceINTEL).[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca19d05c0] [color=#18b218]Intel QSV in OpenCL acquire function found (clEnqueueAcquireVA_APIMediaSurfacesINTEL).[/color] [/font]
[font=monospace][AVHWDeviceContext @ 0x643ca19d05c0] [color=#18b218]Intel QSV in OpenCL release function found (clEnqueueReleaseVA_APIMediaSurfacesINTEL).[/color] [/font]
[font=monospace]Hyper fast Audio and Video encoder [/font]
[font=monospace]usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options] outfile}... [/font]

[font=monospace][color=#b26818]Use -h to get full help or, even better, run 'man ffmpeg'[/color]



Any help would be greatly appreciated! TIA.


RE: Hardware acceleration - cannot get it to work - TheDreadPirate - 2024-10-25

The 12600K does not support AV1 encoding. Only AV1 decoding. Uncheck "Allow encoding in AV1 format".


RE: Hardware acceleration - cannot get it to work - performation - 2024-10-25

Oh wow I feel so stupid. I must have read that option 10 times and always read decoding... Yeah, it works not, thanks so much.