[SCM] libav/experimental: fixed last zero mv for field - fixed mismatch handling for intra coefs

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 15:29:53 UTC 2013


The following commit has been merged in the experimental branch:
commit d753173a55f6615baa108a0a664eccfe07568290
Author: Fabrice Bellard <fabrice at bellard.org>
Date:   Sat Aug 11 22:08:23 2001 +0000

    fixed last zero mv for field - fixed mismatch handling for intra coefs
    
    
    Originally committed as revision 75 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavcodec/mpeg12.c b/libavcodec/mpeg12.c
index a0f8a65..25b8bab 100644
--- a/libavcodec/mpeg12.c
+++ b/libavcodec/mpeg12.c
@@ -633,6 +633,8 @@ static int mpeg_decode_mb(MpegEncContext *s,
         s->mv_type = MV_TYPE_16X16;
         s->last_mv[0][0][0] = 0;
         s->last_mv[0][0][1] = 0;
+        s->last_mv[0][1][0] = 0;
+        s->last_mv[0][1][1] = 0;
         s->mv[0][0][0] = 0;
         s->mv[0][0][1] = 0;
     } else if (mb_type & (MB_FOR | MB_BACK)) {
@@ -641,7 +643,7 @@ static int mpeg_decode_mb(MpegEncContext *s,
         for(i=0;i<2;i++) {
             if (mb_type & (MB_FOR >> i)) {
                 s->mv_dir |= (MV_DIR_FORWARD >> i);
-                dprintf("mv_type=%d\n", motion_type);
+                dprintf("motion_type=%d\n", motion_type);
                 switch(motion_type) {
                 case MT_FRAME: /* or MT_16X8 */
                     if (s->picture_structure == PICT_FRAME) {
@@ -1006,7 +1008,6 @@ static int mpeg2_decode_block_intra(MpegEncContext *s,
         scan_table = ff_alternate_vertical_scan;
     else
         scan_table = zigzag_direct;
-    mismatch = 1;
 
     /* DC coef */
     component = (n <= 3 ? 0 : n - 4 + 1);
@@ -1018,6 +1019,7 @@ static int mpeg2_decode_block_intra(MpegEncContext *s,
     s->last_dc[component] = dc;
     block[0] = dc << (3 - s->intra_dc_precision);
     dprintf("dc=%d\n", block[0]);
+    mismatch = block[0] ^ 1;
     i = 1;
     if (s->intra_vlc_format)
         rl = &rl_mpeg2;

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list