0

I have a PC running Windows which is QSV capable. I've found the codec and at least one QSV filter which really speed up decoding and encoding AVC (x264) videos.

But the experience is extremely aggravating, as there is no proper list anywhere that I can find on what the filters and arguments actually are.

The closest I've come vpp_qsv is this:

https://github.com/FFmpeg/FFmpeg/blob/master/libavfilter/vf_vpp_qsv.c

It's a start, but it has no examples of what the arguments actually do or how to use them.

The few examples I've been able to find in various places (including stackoverflow) do not work.

By experimentation, I've found that this works:

ffmpeg -hide_banner -init_hw_device qsv=qsv -hwaccel qsv -i "input.mts" -c:a aac -c:v h264_qsv -preset veryslow -vf "vpp_qsv=cw=628:cx=0:w=640:h=480" -q:v 30 "output.mp4"

I can add other things to the filter. For example:

"vpp_qsv=deinterlace=2:cw=628:cx=0:w=640:h=480"

will work. However, this will NOT work:

"vpp_qsv=cw=628:cx=0:w=640:h=480:async_depth=4"

even though there are examples posted that say it will, and the web page posted above says that async_depth is a valid parameter.

[Parsed_vpp_qsv_0 @ 0000000005bff8c0] Option 'async_depth' not found [AVFilterGraph @ 0000000007327dc0] Error initializing filter 'vpp_qsv' with args 'cw=628:cx=0:w=640:h=480:async_depth=4' Error reinitializing filters! Failed to inject frame into filter network: Option not found Error while processing the decoded data for stream #0:0

I also have been unable to find good examples of using more than one QSV enabled filter at the same time.

I'm using the newest version of ffmpeg I can find:

I:\ffmpeg -version ffmpeg version 4.4-full_build-www.gyan.dev Copyright (c) 2000-2021 the FFmpeg developers built with gcc 10.2.0 (Rev6, Built by MSYS2 project) configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml 2 --enable-gmp --enable-lzma --enable-libsnappy --enable-zlib --enable-librist --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-libbluray --enab le-libcaca --enable-sdl2 --enable-libdav1d --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --ena ble-libaom --enable-libopenjpeg --enable-libvpx --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-libvidstab --enable-libvmaf --enable-lib zimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libglslang - -enable-vulkan --enable-opencl --enable-libcdio --enable-libgme --enable-libmodplug --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libshine - -enable-libtheora --enable-libtwolame --enable-libvo-amrwbenc --enable-libilbc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libv orbis --enable-ladspa --enable-libbs2b --enable-libflite --enable-libmysofa --enable-librubberband --enable-libsoxr --enable-chromaprint libavutil 56. 70.100 / 56. 70.100 libavcodec 58.134.100 / 58.134.100 libavformat 58. 76.100 / 58. 76.100 libavdevice 58. 13.100 / 58. 13.100 libavfilter 7.110.100 / 7.110.100 libswscale 5. 9.100 / 5. 9.100 libswresample 3. 9.100 / 3. 9.100 libpostproc 55. 9.100 / 55. 9.100

and the output of "ffmpeg -filters" says I have the various QSV enabled filters on my system.

I have searched dozens and dozens of sites including Intel and ffmpeg.org and I cannot find a clear explanation of how the various QSV enabled filters work, with examples that will actually execute on my system. Could someone please say where the to look? Someone developed these filters, so someone somewhere must know how they work and why async_depth doesn't work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.