ffmpeg

ffmpeg libx264: whats the difference between crf and profile and preset in terms of quality (bitrate)


In ffmpeg while encoding with libx264 i came across crf, profile and preset

Whats the difference between them in terms bitrate.

And if i am using all the three, will they conflict among each other or which one will be effective.


Solution

  • No they are independent of each other. CRF is a quality setting. Lower is better, but requires more bits. Profile tells the encoder what tools it can expect the decoder to be able to handle (b frames and CABAC for example). The more tools, the better the quality at a given bitrate. High is best, but usually does not do much better than main, and is not supported by older decoders. Use main. Presets are created by a human in an attempt to choose good default settings for each tool by trading encoding time for quality. Slower is better, but requires more CPU time.