aboutsummaryrefslogtreecommitdiffhomepage
path: root/libmpeg2
diff options
context:
space:
mode:
authorGravatar henry <henry@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-11-04 07:05:21 +0000
committerGravatar henry <henry@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-11-04 07:05:21 +0000
commit440d6200acfd98d87ea13d0622066db7e71bb985 (patch)
tree6e3bf6b5ea49febd6f2a53c15c4462b1da49aa79 /libmpeg2
parent46afb40907813caa8a9594e3ab020bb196b9cb28 (diff)
fix quantizer export for interlaced video
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20654 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpeg2')
-rw-r--r--libmpeg2/slice.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/libmpeg2/slice.c b/libmpeg2/slice.c
index 308ff5d456..0cba9f3144 100644
--- a/libmpeg2/slice.c
+++ b/libmpeg2/slice.c
@@ -1569,9 +1569,18 @@ do { \
#define NEXT_MACROBLOCK \
do { \
- if(decoder->quant_store) \
+ if(decoder->quant_store) { \
+ if (decoder->picture_structure == TOP_FIELD) \
+ decoder->quant_store[2*decoder->quant_stride*(decoder->v_offset>>4) \
+ +(decoder->offset>>4)] = decoder->quantizer_scale; \
+ else if (decoder->picture_structure == BOTTOM_FIELD) \
+ decoder->quant_store[2*decoder->quant_stride*(decoder->v_offset>>4) \
+ + decoder->quant_stride \
+ +(decoder->offset>>4)] = decoder->quantizer_scale; \
+ else \
decoder->quant_store[decoder->quant_stride*(decoder->v_offset>>4) \
+(decoder->offset>>4)] = decoder->quantizer_scale; \
+ } \
decoder->offset += 16; \
if (decoder->offset == decoder->width) { \
do { /* just so we can use the break statement */ \