mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-25 01:30:38 +00:00
uridecodebin: Never treat live sources as streaming sources.
For streaming sources a queue is added before the demuxer, which can not be properly filled by live sources. As http source can be live sources, this caused issues for example with http live sources. Fixes https://bugzilla.gnome.org/show_bug.cgi?id=674057
This commit is contained in:
parent
38803239c0
commit
c9ad084e29
1 changed files with 18 additions and 0 deletions
|
@ -1994,6 +1994,21 @@ could_not_link:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static gboolean
|
||||||
|
is_live_source (GstElement * source)
|
||||||
|
{
|
||||||
|
GObjectClass *source_class = NULL;
|
||||||
|
gboolean is_live = FALSE;
|
||||||
|
|
||||||
|
source_class = G_OBJECT_GET_CLASS (source);
|
||||||
|
if (!g_object_class_find_property (source_class, "is-live"))
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
|
g_object_get (G_OBJECT (source), "is-live", &is_live, NULL);
|
||||||
|
|
||||||
|
return is_live;
|
||||||
|
}
|
||||||
|
|
||||||
/* construct and run the source and decoder elements until we found
|
/* construct and run the source and decoder elements until we found
|
||||||
* all the streams or until a preroll queue has been filled.
|
* all the streams or until a preroll queue has been filled.
|
||||||
*/
|
*/
|
||||||
|
@ -2023,6 +2038,9 @@ setup_source (GstURIDecodeBin * decoder)
|
||||||
g_signal_emit (decoder, gst_uri_decode_bin_signals[SIGNAL_SOURCE_SETUP],
|
g_signal_emit (decoder, gst_uri_decode_bin_signals[SIGNAL_SOURCE_SETUP],
|
||||||
0, decoder->source);
|
0, decoder->source);
|
||||||
|
|
||||||
|
if (is_live_source (decoder->source))
|
||||||
|
decoder->is_stream = FALSE;
|
||||||
|
|
||||||
/* remove the old decoders now, if any */
|
/* remove the old decoders now, if any */
|
||||||
remove_decoders (decoder, FALSE);
|
remove_decoders (decoder, FALSE);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue