qscale exporting for postprocess
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>
Sun, 6 Apr 2003 16:37:37 +0000 (16:37 +0000)
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>
Sun, 6 Apr 2003 16:37:37 +0000 (16:37 +0000)
patch by Fabian Franz <FabianFranz@gmx.de>

git-svn-id: svn://git.mplayerhq.hu/mplayer/trunk@9856 b3059339-0415-0410-9bf9-f77b7e298cf2

libmpeg2/mpeg2_internal.h
libmpeg2/slice.c

index 0e364cb..90ae570 100644 (file)
@@ -135,6 +135,10 @@ struct decoder_s {
     int second_field;
 
     int mpeg1;
+
+    /* for MPlayer: */
+    char* quant_store;
+    int   quant_stride;
 };
 
 typedef struct {
index 7f6a2ed..327612e 100644 (file)
@@ -1420,6 +1420,9 @@ do {                                                              \
 
 #define NEXT_MACROBLOCK                                                        \
 do {                                                                   \
+    if(decoder->quant_store)                                           \
+       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 */               \