mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
streamsynchronizer: Unblock EOS wait when track switching.
sink_event () will blocked on EOS event. which will cause can't send event when switch EOS track to non-EOS one. https://bugzilla.gnome.org/show_bug.cgi?id=750761
This commit is contained in:
parent
bd508a343f
commit
d2e942ac02
1 changed files with 19 additions and 0 deletions
|
@ -512,6 +512,25 @@ gst_stream_synchronizer_sink_event (GstPad * pad, GstObject * parent,
|
||||||
self->group_start_time = new_group_start_time;
|
self->group_start_time = new_group_start_time;
|
||||||
GST_STREAM_SYNCHRONIZER_UNLOCK (self);
|
GST_STREAM_SYNCHRONIZER_UNLOCK (self);
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
|
/* unblocking EOS wait when track switch. */
|
||||||
|
case GST_EVENT_CUSTOM_DOWNSTREAM_OOB:{
|
||||||
|
if (gst_event_has_name (event, "playsink-custom-video-flush")
|
||||||
|
|| gst_event_has_name (event, "playsink-custom-audio-flush")
|
||||||
|
|| gst_event_has_name (event, "playsink-custom-subtitle-flush")) {
|
||||||
|
GstStream *stream;
|
||||||
|
|
||||||
|
GST_STREAM_SYNCHRONIZER_LOCK (self);
|
||||||
|
stream = gst_pad_get_element_private (pad);
|
||||||
|
if (stream) {
|
||||||
|
stream->is_eos = FALSE;
|
||||||
|
stream->eos_sent = FALSE;
|
||||||
|
stream->wait = FALSE;
|
||||||
|
g_cond_broadcast (&stream->stream_finish_cond);
|
||||||
|
}
|
||||||
|
GST_STREAM_SYNCHRONIZER_UNLOCK (self);
|
||||||
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
case GST_EVENT_EOS:{
|
case GST_EVENT_EOS:{
|
||||||
GstStream *stream;
|
GstStream *stream;
|
||||||
|
|
Loading…
Reference in a new issue