[Ffmpeg-devel] X264 ratecontrol wrapper

Loren Merritt lorenm
Tue Mar 14 06:38:50 CET 2006

On Mon, 13 Mar 2006, M?ns Rullg?rd wrote:
> Michael Niedermayer <michaelni at gmx.at> writes:
>> is anyone interrested in writing a ratecontrol wraper for
>> ffmpeg-x264 similar to ffmpeg-xvid so all our codecs could use the
>> x264 rc code?
> The problem I see here is with the different quantizer range and
> qp/bitrate relationship.  Do you have a good mapping of the H.264 qp
> onto an equivalent mpeg2/4 quantizer?

All you need to know is that h264's qp is proportional to 6*log2(mpeg qp).
It doesn't matter what the constant of proportionality is, since you do 
the inverse translation when generating the stats.
Different range: just set qpmin/max appropriately.

--Loren Merritt

More information about the ffmpeg-devel mailing list