From 4108069d0552c683100ee0087b7c2f83a91e0b2d Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Sat, 10 Jan 2015 15:40:30 +1100 Subject: [PATCH] inter: interaudiosrc - fixate layout for default caps Makes interaudiosrc produce valid audio caps in the absence of any other guidance by adding to the pad template and fixate function --- gst/inter/gstinteraudiosrc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gst/inter/gstinteraudiosrc.c b/gst/inter/gstinteraudiosrc.c index 285007902d..911bb8f0e7 100644 --- a/gst/inter/gstinteraudiosrc.c +++ b/gst/inter/gstinteraudiosrc.c @@ -85,7 +85,8 @@ static GstStaticPadTemplate gst_inter_audio_src_src_template = GST_STATIC_PAD_TEMPLATE ("src", GST_PAD_SRC, GST_PAD_ALWAYS, - GST_STATIC_CAPS (GST_AUDIO_CAPS_MAKE (GST_AUDIO_FORMATS_ALL)) + GST_STATIC_CAPS (GST_AUDIO_CAPS_MAKE (GST_AUDIO_FORMATS_ALL) + ", layout = (string) interleaved") ); @@ -477,6 +478,7 @@ gst_inter_audio_src_fixate (GstBaseSrc * src, GstCaps * caps) gst_structure_fixate_field_string (structure, "format", GST_AUDIO_NE (S16)); gst_structure_fixate_field_nearest_int (structure, "channels", 2); gst_structure_fixate_field_nearest_int (structure, "rate", 48000); + gst_structure_fixate_field_string (structure, "layout", "interleaved"); return caps; } -- 2.34.1