diff options
author | Tim-Philipp Müller <tim.muller@collabora.co.uk> | 2009-03-25 01:22:17 +0000 |
---|---|---|
committer | Tim-Philipp Müller <tim.muller@collabora.co.uk> | 2009-03-25 10:36:49 +0000 |
commit | 297bbfbebc7bf03cd94e89a4ef7b9660a6cf3e9c (patch) | |
tree | cbd9825d5c8a915f8395a4db22cf47624eaaaf91 /gst/rtp | |
parent | ab1bbcd58d2a6f5c07b516c14d9e5a8b6e0b2749 (diff) |
rtpmp4apay: warn if input is unframed
Diffstat (limited to 'gst/rtp')
-rw-r--r-- | gst/rtp/gstrtpmp4apay.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/gst/rtp/gstrtpmp4apay.c b/gst/rtp/gstrtpmp4apay.c index efa30955..6d18bd06 100644 --- a/gst/rtp/gstrtpmp4apay.c +++ b/gst/rtp/gstrtpmp4apay.c @@ -37,11 +37,13 @@ GST_ELEMENT_DETAILS ("RTP MPEG4 audio payloader", "Payload MPEG4 audio as RTP packets (RFC 3016)", "Wim Taymans <wim.taymans@gmail.com>"); +/* FIXME: add framed=(boolean)true once our encoders have this field set + * on their output caps */ static GstStaticPadTemplate gst_rtp_mp4a_pay_sink_template = GST_STATIC_PAD_TEMPLATE ("sink", GST_PAD_SINK, GST_PAD_ALWAYS, - GST_STATIC_CAPS ("audio/mpeg," "mpegversion=(int) 4") + GST_STATIC_CAPS ("audio/mpeg, mpegversion=(int)4") ); static GstStaticPadTemplate gst_rtp_mp4a_pay_src_template = @@ -280,7 +282,7 @@ gst_rtp_mp4a_pay_setcaps (GstBaseRTPPayload * payload, GstCaps * caps) GstRtpMP4APay *rtpmp4apay; GstStructure *structure; const GValue *codec_data; - gboolean res; + gboolean res, framed = TRUE; rtpmp4apay = GST_RTP_MP4A_PAY (payload); @@ -339,6 +341,10 @@ gst_rtp_mp4a_pay_setcaps (GstBaseRTPPayload * payload, GstCaps * caps) } } + if (gst_structure_get_boolean (structure, "framed", &framed) && !framed) { + GST_WARNING_OBJECT (payload, "Need framed AAC data as input!"); + } + gst_basertppayload_set_options (payload, "audio", TRUE, "MP4A-LATM", rtpmp4apay->rate); |