ffprobe: print start_pts and duration_ts stream information
authorStefano Sabatini <stefasab@gmail.com>
Sat, 8 Sep 2012 11:00:13 +0000 (13:00 +0200)
committerStefano Sabatini <stefasab@gmail.com>
Wed, 12 Sep 2012 08:22:29 +0000 (10:22 +0200)
doc/ffprobe.xsd
ffprobe.c

index 4340d46..c9213de 100644 (file)
       <xsd:attribute name="r_frame_rate"     type="xsd:string" use="required"/>
       <xsd:attribute name="avg_frame_rate"   type="xsd:string" use="required"/>
       <xsd:attribute name="time_base"        type="xsd:string" use="required"/>
+      <xsd:attribute name="start_pts"        type="xsd:long"/>
       <xsd:attribute name="start_time"       type="xsd:float"/>
+      <xsd:attribute name="duration_ts"      type="xsd:long"/>
       <xsd:attribute name="duration"         type="xsd:float"/>
       <xsd:attribute name="bit_rate"         type="xsd:int"/>
       <xsd:attribute name="nb_frames"        type="xsd:int"/>
index 66fba70..06af4c3 100644 (file)
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -1715,8 +1715,10 @@ static void show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_i
     print_q("r_frame_rate",   stream->r_frame_rate,   '/');
     print_q("avg_frame_rate", stream->avg_frame_rate, '/');
     print_q("time_base",      stream->time_base,      '/');
-    print_time("start_time",    stream->start_time, &stream->time_base);
-    print_time("duration",      stream->duration,   &stream->time_base);
+    print_ts  ("start_pts",   stream->start_time);
+    print_time("start_time",  stream->start_time, &stream->time_base);
+    print_ts  ("duration_ts", stream->duration);
+    print_time("duration",    stream->duration, &stream->time_base);
     if (dec_ctx->bit_rate > 0) print_val    ("bit_rate", dec_ctx->bit_rate, unit_bit_per_second_str);
     else                       print_str_opt("bit_rate", "N/A");
     if (stream->nb_frames) print_fmt    ("nb_frames", "%"PRId64, stream->nb_frames);