aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/msmpeg4.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2002-01-13 06:12:35 +0000
committerMichael Niedermayer <michaelni@gmx.at>2002-01-13 06:12:35 +0000
commit99180fe39d9a65eb803718a8f6004a11231bc734 (patch)
tree878dfb84ee0919e1b1644841ac848e3a3ee5adda /libavcodec/msmpeg4.c
parentbadaf88eeb4602afec502b5822d05fc8bb9da05b (diff)
downloadffmpeg-99180fe39d9a65eb803718a8f6004a11231bc734.tar.gz
(commit by michael)
new msmpeg4 dequantizer did dequantize too early Originally committed as revision 261 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/msmpeg4.c')
-rw-r--r--libavcodec/msmpeg4.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/msmpeg4.c b/libavcodec/msmpeg4.c
index 2d5d3dd23b..c8df0c4153 100644
--- a/libavcodec/msmpeg4.c
+++ b/libavcodec/msmpeg4.c
@@ -868,9 +868,10 @@ static int msmpeg4_decode_block(MpegEncContext * s, DCTELEM * block,
if (code < 0 || code >= rl->n)
return -1;
run = rl->table_run[code];
- level = rl->table_level[code] * qmul + qadd;
+ level = rl->table_level[code];
last = code >= rl->last;
run += rl->max_run[last][level] + run_diff;
+ level= level * qmul + qadd;
if (get_bits1(&s->gb))
level = -level;
}