aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Converse <alex.converse@gmail.com>2011-06-06 10:59:46 -0700
committerAlex Converse <alex.converse@gmail.com>2011-06-09 10:14:32 -0700
commit85e9e3a9fa9c79bb3b4af74d15c7aa62f29515ce (patch)
tree9db58a1d7448c2a16c38c42cad0a6c9280818b1b
parent9a1b79128c25a5c1004bbd0af85a68c9a2a3e580 (diff)
downloadffmpeg-85e9e3a9fa9c79bb3b4af74d15c7aa62f29515ce.tar.gz
movdec: Add support for the 'wfex' atom.
The 'wfex' is just a Microsoft WaveFormatEx struct.
-rw-r--r--libavformat/mov.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 245933da3a..4d3f4f69d2 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -508,6 +508,19 @@ static int mov_read_dac3(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return 0;
}
+static int mov_read_wfex(MOVContext *c, AVIOContext *pb, MOVAtom atom)
+{
+ AVStream *st;
+
+ if (c->fc->nb_streams < 1)
+ return 0;
+ st = c->fc->streams[c->fc->nb_streams-1];
+
+ ff_get_wav_header(pb, st->codec, atom.size);
+
+ return 0;
+}
+
static int mov_read_pasp(MOVContext *c, AVIOContext *pb, MOVAtom atom)
{
const int num = avio_rb32(pb);
@@ -2247,6 +2260,7 @@ static const MOVParseTableEntry mov_default_parse_table[] = {
{ MKTAG('e','s','d','s'), mov_read_esds },
{ MKTAG('d','a','c','3'), mov_read_dac3 }, /* AC-3 info */
{ MKTAG('w','i','d','e'), mov_read_wide }, /* place holder */
+{ MKTAG('w','f','e','x'), mov_read_wfex },
{ MKTAG('c','m','o','v'), mov_read_cmov },
{ 0, NULL }
};