From: Gilbok Lee Date: Tue, 16 Nov 2021 01:14:04 +0000 (+0900) Subject: hlsdemux: Add condition for setting stream discontinuity X-Git-Tag: accepted/tizen/unified/20220217.153506~2^2~10^2~9^2~12^2~2^2~11 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fupstream%2Fgstreamer.git;a=commitdiff_plain;h=61810b61928d0e1b0708c836a1c11a12522173b8 hlsdemux: Add condition for setting stream discontinuity - Set stream continuity when fragment time changes - Change in the wrong define in the spec Change-Id: I592f4cd915c2d186462f771714de797c4b424521 --- diff --git a/ext/hls/gsthlsdemux.c b/ext/hls/gsthlsdemux.c index 3e7da32..25e7a07 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), diff --git a/packaging/gst-plugins-bad.spec b/packaging/gst-plugins-bad.spec index 1e8821c..9a7a4a6 100644 --- a/packaging/gst-plugins-bad.spec +++ b/packaging/gst-plugins-bad.spec @@ -82,7 +82,7 @@ export CFLAGS+=" -Wall -g -fPIC\ -DTIZEN_FEATURE_ADAPTIVE_MODIFICATION\ -DTIZEN_FEATURE_HLSDEMUX_PROPERTY\ -DTIZEN_FEATURE_TSDEMUX_MODIFICATION\ - -DTIZEN_FEATURE_TSDEMUX_WRONG_PCR_PID\ + -DTIZEN_FEATURE_TSDEMUX_INVALID_PCR_PID\ -DTIZEN_FEATURE_TSDEMUX_LANG_TAG\ -DTIZEN_FEATURE_HLS_WEBVTT\ -DTIZEN_FEATURE_OALSINK_MODIFICATION\