From: Gilbok Lee Date: Tue, 16 Nov 2021 01:14:04 +0000 (+0900) Subject: hlsdemux: Add condition for setting stream discontinuity X-Git-Tag: submit/tizen_6.0/20211117.042908^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=865a70d531964021e7b4490c326cebf7428c87cd;p=platform%2Fupstream%2Fgst-plugins-bad.git hlsdemux: Add condition for setting stream discontinuity - Set stream continuity when fragment time changes Change-Id: I592f4cd915c2d186462f771714de797c4b424521 --- diff --git a/ext/hls/gsthlsdemux.c b/ext/hls/gsthlsdemux.c index 3e7da322e..25e7a07f1 100644 --- a/ext/hls/gsthlsdemux.c +++ b/ext/hls/gsthlsdemux.c @@ -1328,7 +1328,8 @@ gst_hls_demux_handle_buffer (GstAdaptiveDemux * demux, #ifdef TIZEN_FEATURE_HLSDEMUX_DISCONT if (!stream->discont && GST_CLOCK_TIME_IS_VALID (hls_stream->last_pcr) && GST_CLOCK_TIME_IS_VALID (last_pcr)) { - if (G_UNLIKELY (ABSDIFF (hls_stream->last_pcr, last_pcr) > 1 * GST_SECOND)) { + if (G_UNLIKELY (ABSDIFF (hls_stream->last_pcr, last_pcr) > 1 * GST_SECOND) + && (stream->fragment.timestamp != hls_stream->sequence_pos)) { GST_DEBUG_OBJECT (stream->pad, "Overwriting fragment timestamp [%" GST_TIME_FORMAT "] to [%" GST_TIME_FORMAT "]", GST_TIME_ARGS (stream->fragment.timestamp),