# HG changeset patch # User michaelni # Date 1065084757 0 # Node ID 37e16bd36d2ca5ca902e04e331b05c8964053475 # Parent b78a9ba6a568622762e53f1b2eaebaf8c31e6d7d rd cbp + single coeff elimination fix diff -r b78a9ba6a568 -r 37e16bd36d2c mpegvideo.c --- a/mpegvideo.c Thu Oct 02 05:20:07 2003 +0000 +++ b/mpegvideo.c Thu Oct 02 08:52:37 2003 +0000 @@ -3025,12 +3025,6 @@ }else s->block_last_index[i]= -1; } - if(s->flags & CODEC_FLAG_CBP_RD){ - for(i=0;i<6;i++) { - if(s->block_last_index[i] == -1) - s->coded_score[i]= INT_MAX/256; - } - } if(s->luma_elim_threshold && !s->mb_intra) for(i=0; i<4; i++) @@ -3038,6 +3032,13 @@ if(s->chroma_elim_threshold && !s->mb_intra) for(i=4; i<6; i++) dct_single_coeff_elimination(s, i, s->chroma_elim_threshold); + + if(s->flags & CODEC_FLAG_CBP_RD){ + for(i=0;i<6;i++) { + if(s->block_last_index[i] == -1) + s->coded_score[i]= INT_MAX/256; + } + } } if((s->flags&CODEC_FLAG_GRAY) && s->mb_intra){