aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mpegvideo.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-07-21 01:34:05 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-07-21 01:34:05 +0000
commit3e6a20a0cd4f33fdd1cc3844277f3658ee1e14b8 (patch)
tree261380162000b80c6fb96de45f5576c59623d26d /libavcodec/mpegvideo.c
parent4afeaec92faaa57c9c22813a8bd02d5bd4460f33 (diff)
downloadffmpeg-3e6a20a0cd4f33fdd1cc3844277f3658ee1e14b8.tar.gz
minor optimizations
fixing numbers.avi fixing ac prediction between MBs with different QP Originally committed as revision 782 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mpegvideo.c')
-rw-r--r--libavcodec/mpegvideo.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c
index e41a63f084..0cbe85934a 100644
--- a/libavcodec/mpegvideo.c
+++ b/libavcodec/mpegvideo.c
@@ -270,9 +270,9 @@ int MPV_common_init(MpegEncContext *s)
/* cbp, ac_pred, pred_dir */
CHECKED_ALLOCZ(s->cbp_table , s->mb_num * sizeof(UINT8))
CHECKED_ALLOCZ(s->pred_dir_table, s->mb_num * sizeof(UINT8))
-
- CHECKED_ALLOCZ(s->qscale_table , s->mb_num * sizeof(UINT8))
}
+ CHECKED_ALLOCZ(s->qscale_table , s->mb_num * sizeof(UINT8))
+
/* default structure is frame */
s->picture_structure = PICT_FRAME;
@@ -1414,8 +1414,10 @@ void MPV_decode_mb(MpegEncContext *s, DCTELEM block[6][64])
quant_store[mb_y][mb_x]=s->qscale;
//printf("[%02d][%02d] %d\n",mb_x,mb_y,s->qscale);
#else
+ /* even more obsolete, exists for mplayer xp only */
if(s->avctx->quant_store) s->avctx->quant_store[mb_y*s->avctx->qstride+mb_x] = s->qscale;
#endif
+ s->qscale_table[mb_xy]= s->qscale;
/* update DC predictors for P macroblocks */
if (!s->mb_intra) {