[SCM] libav/experimental: Force codec_tag I420 for Quicktime Planar Y'CbCr 8-bit 4:2:0 raw codec, because YV12 triggers an UV swap in rawdec.c, fixes issue 1687.

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 16:58:34 UTC 2013


The following commit has been merged in the experimental branch:
commit 895a9be60cd34b347a40dc6b0323c9c731084476
Author: Carl Eugen Hoyos <cehoyos at rainbow.studorg.tuwien.ac.at>
Date:   Sun Jan 24 21:37:35 2010 +0000

    Force codec_tag I420 for Quicktime Planar Y'CbCr 8-bit 4:2:0 raw codec,
    because YV12 triggers an UV swap in rawdec.c, fixes issue 1687.
    
    Originally committed as revision 21436 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavformat/mov.c b/libavformat/mov.c
index b824620..4765f18 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -939,6 +939,9 @@ static int mov_read_stsd(MOVContext *c, ByteIOContext *pb, MOVAtom atom)
                     PUT_UTF8(codec_name[i+1], tmp, st->codec->codec_name[pos++] = tmp;)
                 }
                 st->codec->codec_name[pos] = 0;
+                /* codec_tag YV12 triggers an UV swap in rawdec.c */
+                if (!memcmp(st->codec->codec_name, "Planar Y'CbCr 8-bit 4:2:0", 25))
+                    st->codec->codec_tag=MKTAG('I', '4', '2', '0');
             }
 
             st->codec->bits_per_coded_sample = get_be16(pb); /* depth */

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list