Mercurial > libavcodec.hg
diff h263.c @ 10636:703cfed31320 libavcodec
Move ff_init_qscale_tab() from h263.c to mpegvideo, the function is not h263 specific.
author | michael |
---|---|
date | Thu, 03 Dec 2009 21:36:58 +0000 |
parents | 95f3daa991a2 |
children | f56b8a9be9e1 |
line wrap: on
line diff
--- a/h263.c Thu Dec 03 19:19:57 2009 +0000 +++ b/h263.c Thu Dec 03 21:36:58 2009 +0000 @@ -504,20 +504,6 @@ } /** - * init s->current_picture.qscale_table from s->lambda_table - */ -static void ff_init_qscale_tab(MpegEncContext *s){ - int8_t * const qscale_table= s->current_picture.qscale_table; - int i; - - for(i=0; i<s->mb_num; i++){ - unsigned int lam= s->lambda_table[ s->mb_index2xy[i] ]; - int qp= (lam*139 + FF_LAMBDA_SCALE*64) >> (FF_LAMBDA_SHIFT + 7); - qscale_table[ s->mb_index2xy[i] ]= av_clip(qp, s->avctx->qmin, s->avctx->qmax); - } -} - -/** * modify qscale so that encoding is acually possible in h263 (limit difference to -2..2) */ void ff_clean_h263_qscales(MpegEncContext *s){