1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00
Originally committed as revision 336 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Michael Niedermayer 2002-03-17 18:08:11 +00:00
parent 001e3f555d
commit c674115939

View File

@ -1675,6 +1675,7 @@ static int rate_estimate_qscale(MpegEncContext *s)
diff= s->total_bits - wanted_bits;
br_compensation= (s->bit_rate_tolerance - diff)/s->bit_rate_tolerance;
if(br_compensation<=0.0) br_compensation=0.001;
q/=br_compensation;
qscale= (int)(q + 0.5);