summaryrefslogtreecommitdiffstats
path: root/gst/qtdemux
diff options
context:
space:
mode:
authorEdward Hervey <bilboed@bilboed.com>2007-06-14 10:23:20 +0000
committerEdward Hervey <bilboed@bilboed.com>2007-06-14 10:23:20 +0000
commit98165a69eeb1236c9aa189e24acbf8be442131d3 (patch)
tree39d0b9c34e06becb2ec02bdb27d9798790e103ca /gst/qtdemux
parent2826212827b04ab9a9e26c2f057e45f0e6d6e14b (diff)
gst/qtdemux/qtdemux.c: For AMR-NB streams, export the AMRSpecificBox as codec_data on the caps.
Original commit message from CVS: * gst/qtdemux/qtdemux.c: (qtdemux_parse_trak): For AMR-NB streams, export the AMRSpecificBox as codec_data on the caps. Fixes #447458
Diffstat (limited to 'gst/qtdemux')
-rw-r--r--gst/qtdemux/qtdemux.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/gst/qtdemux/qtdemux.c b/gst/qtdemux/qtdemux.c
index ce3f18b1..1b1d9519 100644
--- a/gst/qtdemux/qtdemux.c
+++ b/gst/qtdemux/qtdemux.c
@@ -3021,6 +3021,21 @@ qtdemux_parse_trak (GstQTDemux * qtdemux, GNode * trak)
"samplesize", G_TYPE_INT, samplesize, NULL);
break;
}
+ case FOURCC_samr:
+ {
+ gint len = QT_UINT32 (stsd_data);
+
+ if (len > 0x34) {
+ GstBuffer *buf = gst_buffer_new_and_alloc (len - 0x34);
+
+ memcpy (GST_BUFFER_DATA (buf), stsd_data + 0x34, len - 0x34);
+
+ gst_caps_set_simple (stream->caps,
+ "codec_data", GST_TYPE_BUFFER, buf, NULL);
+ gst_buffer_unref (buf);
+ }
+ break;
+ }
default:
break;
}