diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2010-03-15 16:37:02 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2010-03-15 16:37:02 +0000 |
commit | bd57cae86fb2032f2e49c8909b2da72c3076254c (patch) | |
tree | 233b40d6e0cc0e5458b329b92a52d53f024e2bcd /libavcodec | |
parent | db128802c5f79983c6ee48898607eebabf2c56e7 (diff) | |
download | ffmpeg-bd57cae86fb2032f2e49c8909b2da72c3076254c.tar.gz |
use mpeg2 quantization bias for mjpeg.
this seems to improve RD performance.
Originally committed as revision 22550 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/mpegvideo_enc.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c index cb41c57398..4d282951fc 100644 --- a/libavcodec/mpegvideo_enc.c +++ b/libavcodec/mpegvideo_enc.c @@ -503,10 +503,7 @@ av_cold int MPV_encode_init(AVCodecContext *avctx) // return -1; } - if(s->codec_id==CODEC_ID_MJPEG){ - s->intra_quant_bias= 1<<(QUANT_BIAS_SHIFT-1); //(a + x/2)/x - s->inter_quant_bias= 0; - }else if(s->mpeg_quant || s->codec_id==CODEC_ID_MPEG1VIDEO || s->codec_id==CODEC_ID_MPEG2VIDEO){ + if(s->mpeg_quant || s->codec_id==CODEC_ID_MPEG1VIDEO || s->codec_id==CODEC_ID_MPEG2VIDEO || s->codec_id==CODEC_ID_MJPEG){ s->intra_quant_bias= 3<<(QUANT_BIAS_SHIFT-3); //(a + x*3/8)/x s->inter_quant_bias= 0; }else{ |