mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-17 03:35:21 +00:00
composition: push flush events on the target.
This commit is contained in:
parent
1d089e8c80
commit
9bd96f9770
1 changed files with 8 additions and 13 deletions
|
@ -1778,7 +1778,6 @@ _set_current_bin_to_ready (GnlComposition * comp, gboolean flush_downstream)
|
|||
ptarget = gst_ghost_pad_get_target (GST_GHOST_PAD (GNL_OBJECT_SRC (comp)));
|
||||
if (ptarget) {
|
||||
GstEvent *flush_event;
|
||||
GstPad *peer = gst_pad_get_peer (GNL_OBJECT_SRC (comp));
|
||||
|
||||
/* Make sure that between the flush_start/flush_stop
|
||||
* and the time we set the current_bin to READY, no
|
||||
|
@ -1790,19 +1789,15 @@ _set_current_bin_to_ready (GnlComposition * comp, gboolean flush_downstream)
|
|||
|
||||
GST_DEBUG_OBJECT (comp, "added event probe %lu", priv->ghosteventprobe);
|
||||
|
||||
if (peer) {
|
||||
flush_event = gst_event_new_flush_start ();
|
||||
priv->flush_seqnum = gst_event_get_seqnum (flush_event);
|
||||
GST_INFO_OBJECT (comp, "sending flushes downstream with seqnum %d",
|
||||
priv->flush_seqnum);
|
||||
gst_pad_send_event (peer, flush_event);
|
||||
flush_event = gst_event_new_flush_start ();
|
||||
priv->flush_seqnum = gst_event_get_seqnum (flush_event);
|
||||
GST_INFO_OBJECT (comp, "sending flushes downstream with seqnum %d",
|
||||
priv->flush_seqnum);
|
||||
gst_pad_push_event (ptarget, flush_event);
|
||||
|
||||
flush_event = gst_event_new_flush_stop (TRUE);
|
||||
gst_event_set_seqnum (flush_event, priv->flush_seqnum);
|
||||
gst_pad_send_event (peer, flush_event);
|
||||
|
||||
gst_object_unref (peer);
|
||||
}
|
||||
flush_event = gst_event_new_flush_stop (TRUE);
|
||||
gst_event_set_seqnum (flush_event, priv->flush_seqnum);
|
||||
gst_pad_push_event (ptarget, flush_event);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue