Commit 4bbd5537 authored by michael's avatar michael

use lambda/lmax instead of qscale/qmax as end check for vbv retry


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@6822 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 1d92aefd
......@@ -2535,7 +2535,7 @@ vbv_retry:
RateControlContext *rcc= &s->rc_context;
int max_size= rcc->buffer_index/3;
if(put_bits_count(&s->pb) > max_size && s->qscale < s->avctx->qmax){
if(put_bits_count(&s->pb) > max_size && s->lambda < s->avctx->lmax){
s->next_lambda= FFMAX(s->lambda+1, s->lambda*(s->qscale+1) / s->qscale);
s->mb_skipped = 0; //done in MPV_frame_start()
if(s->pict_type==P_TYPE){ //done in encode_picture() so we must undo it
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment