[0.11] gst-plugins-ugly: amrnb: Add the new layout field to the raw audio caps

Sebastian Dröge slomo at kemper.freedesktop.org
Thu Jan 5 01:37:14 PST 2012


Module: gst-plugins-ugly
Branch: 0.11
Commit: 3eae4839f20965ecacc531778bcf74b5d35b79c0
URL:    http://cgit.freedesktop.org/gstreamer/gst-plugins-ugly/commit/?id=3eae4839f20965ecacc531778bcf74b5d35b79c0

Author: Sebastian Dröge <sebastian.droege at collabora.co.uk>
Date:   Wed Jan  4 15:42:29 2012 +0100

amrnb: Add the new layout field to the raw audio caps

---

 ext/amrnb/amrnbdec.c |    3 +++
 ext/amrnb/amrnbenc.c |    1 +
 2 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/ext/amrnb/amrnbdec.c b/ext/amrnb/amrnbdec.c
index a2c9e36..180beff 100644
--- a/ext/amrnb/amrnbdec.c
+++ b/ext/amrnb/amrnbdec.c
@@ -48,6 +48,7 @@ static GstStaticPadTemplate src_template = GST_STATIC_PAD_TEMPLATE ("src",
     GST_PAD_SRC,
     GST_PAD_ALWAYS,
     GST_STATIC_CAPS ("audio/x-raw, format = (string) " GST_AUDIO_NE (S16) ", "
+        "layout = (string) interleaved, "
         "rate = (int) 8000," "channels = (int) 1")
     );
 
@@ -222,8 +223,10 @@ gst_amrnbdec_set_format (GstAudioDecoder * dec, GstCaps * caps)
   /* create reverse caps */
   copy = gst_caps_new_simple ("audio/x-raw",
       "format", G_TYPE_STRING, GST_AUDIO_NE (S16),
+      "layout", G_TYPE_STRING, "interleaved",
       "channels", G_TYPE_INT, amrnbdec->channels,
       "rate", G_TYPE_INT, amrnbdec->rate, NULL);
+
   gst_audio_decoder_set_outcaps (dec, copy);
   gst_caps_unref (copy);
 
diff --git a/ext/amrnb/amrnbenc.c b/ext/amrnb/amrnbenc.c
index 0dc3288..e2df550 100644
--- a/ext/amrnb/amrnbenc.c
+++ b/ext/amrnb/amrnbenc.c
@@ -76,6 +76,7 @@ static GstStaticPadTemplate sink_template = GST_STATIC_PAD_TEMPLATE ("sink",
     GST_PAD_SINK,
     GST_PAD_ALWAYS,
     GST_STATIC_CAPS ("audio/x-raw, format = (string) " GST_AUDIO_NE (S16) ", "
+        "layout = (string) interleaved, "
         "rate = (int) 8000," "channels = (int) 1")
     );
 



More information about the gstreamer-commits mailing list