hlsdemux: No need to have a I-Frame list to do trick modes

It just works cleanly without any index and there is no real reason for
that limitation. Also, there are very few stream with that feature.

https://bugzilla.gnome.org/show_bug.cgi?id=734445
This commit is contained in:
Thibault Saunier 2014-07-21 14:42:47 +02:00 committed by Thibault Saunier
parent 03031037fa
commit 123953d429

View file

@ -430,14 +430,6 @@ gst_hls_demux_src_event (GstPad * pad, GstObject * parent, GstEvent * event)
return FALSE;
}
if ((rate > 1.0 || rate < -1.0) && (!demux->client->main
|| !demux->client->main->iframe_lists)) {
GST_ERROR_OBJECT (demux,
"Trick modes only allowed for streams with I-frame lists");
gst_event_unref (event);
return FALSE;
}
GST_DEBUG_OBJECT (demux, "seek event, rate: %f start: %" GST_TIME_FORMAT
" stop: %" GST_TIME_FORMAT, rate, GST_TIME_ARGS (start),
GST_TIME_ARGS (stop));
@ -466,7 +458,8 @@ gst_hls_demux_src_event (GstPad * pad, GstObject * parent, GstEvent * event)
}
/* Use I-frame variants for trick modes */
if ((rate > 1.0 || rate < -1.0) && demux->segment.rate >= -1.0
if (demux->client->main->iframe_lists &&
rate < -1.0 && demux->segment.rate >= -1.0
&& demux->segment.rate <= 1.0) {
GError *err = NULL;