aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2011-04-28 10:47:40 +0200
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2011-04-28 10:47:40 +0200
commit2d8d6882a7316a49818778a953648b3770e8f604 (patch)
tree8a5a2b548855b3b6ffb85b2771dec9dc535290bd /libavformat
parentdcf008af34bba5152aa0f0e515a558f9da76484b (diff)
downloadffmpeg-2d8d6882a7316a49818778a953648b3770e8f604.tar.gz
Read channel layout atom in mov files.
Diffstat (limited to 'libavformat')
-rw-r--r--libavformat/mov.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index a44182af81..8bb3580333 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -2180,6 +2180,15 @@ static int mov_read_elst(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return 0;
}
+static int mov_read_chan(MOVContext *c, AVIOContext *pb, MOVAtom atom)
+{
+ if (atom.size < 16)
+ return AVERROR_INVALIDDATA;
+ avio_skip(pb, 4);
+ ff_mov_read_chan(c->fc, atom.size - 4, c->fc->streams[0]->codec);
+ return 0;
+}
+
static const MOVParseTableEntry mov_default_parse_table[] = {
{ MKTAG('a','v','s','s'), mov_read_extradata },
{ MKTAG('c','h','p','l'), mov_read_chpl },
@@ -2233,6 +2242,7 @@ static const MOVParseTableEntry mov_default_parse_table[] = {
{ MKTAG('d','a','c','3'), mov_read_dac3 }, /* AC-3 info */
{ MKTAG('w','i','d','e'), mov_read_wide }, /* place holder */
{ MKTAG('c','m','o','v'), mov_read_cmov },
+{ MKTAG('c','h','a','n'), mov_read_chan },
{ 0, NULL }
};