1
1
I have a Linux box and would like to encode some videos with ffmpeg. I have heard that my CPU (a second gen core i5 processor) has hardware support for h.264 encoding.
Is it possible to get ffmpeg to use this, and if so how?
1
1
I have a Linux box and would like to encode some videos with ffmpeg. I have heard that my CPU (a second gen core i5 processor) has hardware support for h.264 encoding.
Is it possible to get ffmpeg to use this, and if so how?
0
No, it is not. FFMPEG does not support Intel's QuickSync technology. In order to use QuickSync a program has to go via Intel Media SDK which is not available for Linux.
other parts of ffmpeg are Windows only, so I suppose it could add support with enough effort – rogerdpack – 2012-06-11T21:20:21.193
4
As of today, Intel's QuickSync technology is supported on Linux, and is exposed by two primary ways: VAAPI and Intel's Media SDK.
When appropriately configured, you'll get the QuickSync-based encoders via the Intel MediaSDK, namely h264_qsv
and hevc_qsv
. To see encoder usage:
ffmpeg -h encoder=h264_qsv
ffmpeg -h encoder-hevc_qsv
The second method, through the VAAPI APIs, requires that FFmpeg be built with the --enable-vaapi
option passed at the ./configure
stage. This is the default on distributions such as Debian and Arch Linux, and as such, readily available for use out of the box.
To list the available VAAPI-based encoders and filters on an FFmpeg build, run:
$ for i in encoders decoders filters; do
echo $i:; ffmpeg -hide_banner -${i} | egrep -i "vaapi"
done
And on usage:
ffmpeg -h encoder=hevc_vaapi
ffmpeg -h encoder=h264_vaapi
ffmpeg -h encoder=vp8_vaapi
ffmpeg -h encoder=vp9_vaaapi
From the list issued above, its' obvious what each encoder above outputs the video codec to on the output, all the way from H.265/HEVC to VP9.
Platform support varies depending on your platform:
(a). H.264 encoding is supported all the way from Sandybridge (2nd Generation Intel Core Processor graphics) to present.
(b). HEVC encoding is supported on Skylake and beyond, with 10-bit encoding for it available on Kabylake and beyond.
(c). VP8 encoding is available from at least Broadwell (5th Generation Intel Core Processor Graphics) and beyond.
(d). VP9 encoding is available from at least Kabylake and above. Coffelake and beyond will offer 10-bit VP9 encoding.
A few extra notes on encoding quality:
And now, small notes about NVENC, and tuning it for high quality encodes:
Intel's Quick Sync Encoder, like any other hardware-based encoder, has several limitations compared to a pure software encoder such as x264 and x265, namely quality control, and a strict limitation on supported input texture types. As such, if you're considering QuickSync for any professional workflow, kindly evaluate the performance benefit vs the perceptual encoding quality prior to investing in it.
If you're looking at high quality encodes on VAAPI, ensure that you're at least on Haswell (Intel 4th Generation iGPUs), as this architecture introduced features such as the concept of “Target Usage” (TU). This feature is intended to enable simple access to a series of gradations without the complexity around forcing users to select a bit rate and rate control method. On previous iterations, while there were technically seven steps only three were really exposed for consumption: quality (TU1), balanced (TU4), and speed (TU7). This changed with the latest spin of Intel HD graphics, with each step fully selectable and exposed by the Intel media SDK.
Of note are the newer optimizations towards bitrate control algorithms, noteworthy concepts being LA-BRC. Take a look at it here. See this answer for more pointers on the same.
0
x264 access QuickSync without using MediaSDK. Intel reached them and they mutually helped each other to accomplish that (google for "x264 QuickSinc). It may be possible to capitalize on their effort and bring it to ffmpeg...
Just some general thoughts: Those processors are very new and for hardware support to be supported by software takes time. Compilers would need to support it and then later programs too. My Google skills could be bad, but I couldn't find anything on hardware support for Intel® Quick Sync Video on FFMPEG or GCC. – AndrejaKo – 2011-03-04T15:40:35.090
1
There's some interesting discussion here.
– AndrejaKo – 2011-03-04T15:43:56.943