use DTS if PTS is invalid 55/86555/2
authorYounghwan <younghwan_.an@samsung.com>
Fri, 2 Sep 2016 01:08:42 +0000 (10:08 +0900)
committereunhae choi <eunhae1.choi@samsung.com>
Fri, 2 Sep 2016 03:19:28 +0000 (20:19 -0700)
Change-Id: I36a8059f1528846d2a63049f954a8061072b4b48

libs/gst/base/gstbaseparse.c

index 5de825a..2dfcbbe 100644 (file)
@@ -2312,6 +2312,13 @@ gst_base_parse_push_frame (GstBaseParse * parse, GstBaseParseFrame * frame)
 
   buffer = frame->buffer;
 
+#ifdef GST_TIZEN_TV
+  if (!GST_CLOCK_TIME_IS_VALID (GST_BUFFER_PTS (buffer))) {
+    GST_LOG_OBJECT (parse, "invalid pts, set with dts");
+    GST_BUFFER_PTS (buffer) = GST_BUFFER_DTS (buffer);
+  }
+#endif
+
   GST_LOG_OBJECT (parse,
       "processing buffer of size %" G_GSIZE_FORMAT " with dts %" GST_TIME_FORMAT
       ", pts %" GST_TIME_FORMAT ", duration %" GST_TIME_FORMAT,