[FFmpeg-user] Recommended x.264 preset for live x.264 encoding

Tom Evans tevans.uk at googlemail.com
Mon Feb 13 13:57:22 CET 2012

On Mon, Feb 13, 2012 at 12:21 AM, Stas Oskin <stas.oskin at gmail.com> wrote:
> Thanks for the advice, I would love to give it a try, but it seems that
> after recent clean-up there are no longer such presets available in tree.
> Rather there are new preset format now in the "preset" tree.
> So is it safe to use "old" presets, or anything new can be suggested?

In fact, the new preset system is even easier to use than before, as
it simply presents the options from x264.

You can use -profile:v <x264 profile>, -preset:v <x264 preset>,
-tune:v <x264 tuning>, -level and -x264opts crf=NN to control most
aspects of encoding.

Eg, if you want a video at Main at L3.1, then you can use this:

ffmpeg -i input -c:v libx264 -profile:v main -preset:v fast -level 3.1

If that is too slow, you can go faster with the preset.

If you want to improve the quality of the encode, or reduce the
bitrate of the encode, you can lower or higher the crf. A lower crf
will give higher quality, at a higher bitrate, and a higher crf will
give you lower quality, at a lower bitrate.

ffmpeg -i input -c:v libx264 -profile:v main -preset:v fast -level 3.1
-x264opts crf=18

The faster the preset you use, the less efficient the encoding is, ie
it will use a higher bitrate to achieve the same quality.

To see all the profile, presets and tunings available from x264, run
x264 --full-help.



More information about the ffmpeg-user mailing list