From 007234b4acce098143afeb472f2ca6539088aa6f Mon Sep 17 00:00:00 2001 From: Hyunil Date: Mon, 24 Jan 2022 15:37:54 +0900 Subject: [PATCH] Rtsp: Set start position to Range general-header for PLAY, RESUME and seek for Player Change-Id: Iec86b75ce50981eb843d306cfffe52b498df9506 Signed-off-by: Hyunil --- gst/rtsp/gstrtspsrc.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/gst/rtsp/gstrtspsrc.c b/gst/rtsp/gstrtspsrc.c index 3e54c7d..49b0e55 100644 --- a/gst/rtsp/gstrtspsrc.c +++ b/gst/rtsp/gstrtspsrc.c @@ -8887,11 +8887,22 @@ gen_range_header (GstRTSPSrc * src, GstSegment * segment) g_date_time_unref (datetime); g_date_time_unref (prime_epoch); } else { + +#ifdef TIZEN_FEATURE_RTSP_MODIFICATION + if (src->start_position != 0 && segment->position == 0) { + segment->position = src->start_position; + src->start_position = 0; + } +#endif range.unit = GST_RTSP_RANGE_NPT; if (src->range && src->range->min.type == GST_RTSP_TIME_NOW) { range.min.type = GST_RTSP_TIME_NOW; } else { +#ifdef TIZEN_FEATURE_RTSP_MODIFICATION + if (segment->position != 0) + begin_seconds = (gdouble) segment->position / GST_SECOND; +#endif range.min.type = GST_RTSP_TIME_SECONDS; range.min.seconds = begin_seconds; } -- 2.7.4