summaryrefslogtreecommitdiff
path: root/ext/hls/gsthlsdemux.c
diff options
context:
space:
mode:
authorSeungha Yang <sh.yang@lge.com>2017-02-21 20:08:21 +0900
committerSebastian Dröge <sebastian@centricular.com>2017-03-06 10:09:20 +0200
commit3c5eae63c039fa2957753fd8b482234b85c860d9 (patch)
tree4883d2b34e9c3823c960559d4fa68f352397937d /ext/hls/gsthlsdemux.c
parenta5e540bf55dafdfd25192745ccba6066db9f44fe (diff)
downloadgstreamer-plugins-bad-3c5eae63c039fa2957753fd8b482234b85c860d9.tar.gz
hlsdemux: Try to find type at the end of a fragment
hlsdemux tries to find type if given buffer size is large enought to find type (currently the threshold is 2KB), or EOS in some cases. However, since there can be small byte fragments such as WebVTT, demux should try to find type at the end of a fragment https://bugzilla.gnome.org/show_bug.cgi?id=779011
Diffstat (limited to 'ext/hls/gsthlsdemux.c')
-rw-r--r--ext/hls/gsthlsdemux.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/hls/gsthlsdemux.c b/ext/hls/gsthlsdemux.c
index 574485b54..b75e600ca 100644
--- a/ext/hls/gsthlsdemux.c
+++ b/ext/hls/gsthlsdemux.c
@@ -928,6 +928,13 @@ gst_hls_demux_finish_fragment (GstAdaptiveDemux * demux,
}
if (ret == GST_FLOW_OK || ret == GST_FLOW_NOT_LINKED) {
+ if (G_UNLIKELY (hls_stream->pending_typefind_buffer)) {
+ GstBuffer *buf = hls_stream->pending_typefind_buffer;
+ hls_stream->pending_typefind_buffer = NULL;
+
+ gst_hls_demux_handle_buffer (demux, stream, buf, TRUE);
+ }
+
if (hls_stream->pending_pcr_buffer) {
GstBuffer *buf = hls_stream->pending_pcr_buffer;
hls_stream->pending_pcr_buffer = NULL;