summaryrefslogtreecommitdiff
path: root/libavcodec/ratecontrol.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2009-04-17 17:52:58 +0000
committerMichael Niedermayer <michaelni@gmx.at>2009-04-17 17:52:58 +0000
commit25ef00720b168fbfdd29c45d3ed810b1cbc6d575 (patch)
treed707c3f0535fa7108a405d084e2f966e77efb853 /libavcodec/ratecontrol.c
parent9126aea528131cc301a03ce0ec0e1bf19f503988 (diff)
downloadffmpeg-25ef00720b168fbfdd29c45d3ed810b1cbc6d575.tar.gz
Remove 2 useless assignments from ff_rate_control_init() found by CSA.
Originally committed as revision 18573 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/ratecontrol.c')
-rw-r--r--libavcodec/ratecontrol.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/libavcodec/ratecontrol.c b/libavcodec/ratecontrol.c
index e93500f57f..442dc72b5d 100644
--- a/libavcodec/ratecontrol.c
+++ b/libavcodec/ratecontrol.c
@@ -210,7 +210,6 @@ int ff_rate_control_init(MpegEncContext *s)
for(i=0; i<60*30; i++){
double bits= s->avctx->rc_initial_cplx * (i/10000.0 + 1.0)*s->mb_num;
RateControlEntry rce;
- double q;
if (i%((s->gop_size+3)/4)==0) rce.pict_type= FF_I_TYPE;
else if(i%(s->max_b_frames+1)) rce.pict_type= FF_B_TYPE;
@@ -240,9 +239,7 @@ int ff_rate_control_init(MpegEncContext *s)
rcc->mv_bits_sum[rce.pict_type] += rce.mv_bits;
rcc->frame_count[rce.pict_type] ++;
- bits= rce.i_tex_bits + rce.p_tex_bits;
-
- q= get_qscale(s, &rce, rcc->pass1_wanted_bits/rcc->pass1_rc_eq_output_sum, i);
+ get_qscale(s, &rce, rcc->pass1_wanted_bits/rcc->pass1_rc_eq_output_sum, i);
rcc->pass1_wanted_bits+= s->bit_rate/(1/av_q2d(s->avctx->time_base)); //FIXME misbehaves a little for variable fps
}
}