From: Tim-Philipp Müller Date: Sun, 23 Sep 2012 14:48:54 +0000 (+0100) Subject: interleave: add a bunch of FIXMEs X-Git-Tag: 1.19.3~509^2~6510 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ea7f8a919c2e8bc06e68f23f164e92d93926386d;p=platform%2Fupstream%2Fgstreamer.git interleave: add a bunch of FIXMEs Needs some more work, so stream-start, caps and tags are sent in the right order. --- diff --git a/gst/interleave/interleave.c b/gst/interleave/interleave.c index 8a1e84a..547b2d2 100644 --- a/gst/interleave/interleave.c +++ b/gst/interleave/interleave.c @@ -511,6 +511,7 @@ gst_interleave_request_new_pad (GstElement * element, GstPadTemplate * templ, gst_structure_set (s, "channels", G_TYPE_INT, self->channels, NULL); gst_interleave_set_channel_positions (self, s); + /* FIXME: send caps event after stream-start event */ gst_pad_set_active (self->src, TRUE); gst_pad_set_caps (self->src, srccaps); gst_caps_unref (srccaps); @@ -603,6 +604,7 @@ gst_interleave_change_state (GstElement * element, GstStateChange transition) self->timestamp = 0; self->offset = 0; gst_event_replace (&self->pending_segment, NULL); + self->send_stream_start = TRUE; gst_collect_pads_start (self->collect); break; case GST_STATE_CHANGE_PAUSED_TO_PLAYING: @@ -849,6 +851,9 @@ gst_interleave_sink_event (GstCollectPads * pads, GstCollectData * data, event = NULL; break; } + case GST_EVENT_TAG: + GST_FIXME_OBJECT (self, "FIXME: merge tags and send after stream-start"); + break; default: break; } @@ -1178,6 +1183,18 @@ gst_interleave_collected (GstCollectPads * pads, GstInterleave * self) GstMapInfo write_info; GstClockTime timestamp = -1; + /* FIXME: send caps and tags after stream-start */ +#if 0 + if (self->send_stream_start) { + gchar s_id[32]; + + /* stream-start (FIXME: create id based on input ids) */ + g_snprintf (s_id, sizeof (s_id), "interleave-%08x", g_random_int ()); + gst_pad_push_event (self->src, gst_event_new_stream_start (s_id)); + self->send_stream_start = FALSE; + } +#endif + size = gst_collect_pads_available (pads); if (size == 0) goto eos; diff --git a/gst/interleave/interleave.h b/gst/interleave/interleave.h index a11bb21..89d0e4c 100644 --- a/gst/interleave/interleave.h +++ b/gst/interleave/interleave.h @@ -72,6 +72,8 @@ struct _GstInterleave GstInterleaveFunc func; GstPad *src; + + gboolean send_stream_start; }; struct _GstInterleaveClass