mpegdemux: minor debug update
authorEdward Hervey <bilboed@bilboed.com>
Tue, 9 Dec 2014 08:58:03 +0000 (09:58 +0100)
committerEdward Hervey <bilboed@bilboed.com>
Wed, 21 Jan 2015 07:47:48 +0000 (08:47 +0100)
Only show PTS/DTS when they are valid, and include the stream id

gst/mpegdemux/gstmpegdemux.c

index c05a59db6cfd79c6276bb7f7e714fd26fbcf6260..69ca8e1f9ad424a52c11d60aa4c343995cebcb94 100644 (file)
@@ -2241,18 +2241,18 @@ gst_ps_demux_data_cb (GstPESFilter * filter, gboolean first,
     }
     if (filter->pts != -1) {
       demux->next_pts = filter->pts + demux->scr_adjust;
-      GST_LOG_OBJECT (demux, "PTS = %" G_GUINT64_FORMAT
-          "(%" G_GUINT64_FORMAT ")", filter->pts, demux->next_pts);
+      GST_LOG_OBJECT (demux, "stream 0x%02x PTS = orig %" G_GUINT64_FORMAT
+          " (%" G_GUINT64_FORMAT ")", id, filter->pts, demux->next_pts);
     } else
       demux->next_pts = G_MAXUINT64;
 
     if (filter->dts != -1) {
       demux->next_dts = filter->dts + demux->scr_adjust;
+      GST_LOG_OBJECT (demux, "stream 0x%02x DTS = orig %" G_GUINT64_FORMAT
+          " (%" G_GUINT64_FORMAT ")", id, filter->dts, demux->next_dts);
     } else {
       demux->next_dts = demux->next_pts;
     }
-    GST_LOG_OBJECT (demux, "DTS = orig %" G_GUINT64_FORMAT
-        " (%" G_GUINT64_FORMAT ")", filter->dts, demux->next_dts);
 
     demux->current_stream = gst_ps_demux_get_stream (demux, id, stream_type);
   }