[FFmpeg-devel] [PATCH] Add rc_max_rate to ffprobe stream output
Billy Shambrook
billy.shambrook at gmail.com
Sun Jun 1 18:36:36 CEST 2014
---
doc/ffprobe.xsd | 1 +
ffprobe.c | 2 ++
2 files changed, 3 insertions(+)
diff --git a/doc/ffprobe.xsd b/doc/ffprobe.xsd
index 1bc1fb5..2718e69 100644
--- a/doc/ffprobe.xsd
+++ b/doc/ffprobe.xsd
@@ -165,6 +165,7 @@
<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="max_bit_rate" type="xsd:int"/>
<xsd:attribute name="nb_frames" type="xsd:int"/>
<xsd:attribute name="nb_read_frames" type="xsd:int"/>
<xsd:attribute name="nb_read_packets" type="xsd:int"/>
diff --git a/ffprobe.c b/ffprobe.c
index 2380ee1..baeca1d 100644
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -2122,6 +2122,8 @@ static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_id
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 (dec_ctx->rc_max_rate > 0) print_val ("max_bit_rate", dec_ctx->rc_max_rate, unit_bit_per_second_str);
+ else print_str_opt("max_bit_rate", "N/A");
if (stream->nb_frames) print_fmt ("nb_frames", "%"PRId64, stream->nb_frames);
else print_str_opt("nb_frames", "N/A");
if (nb_streams_frames[stream_idx]) print_fmt ("nb_read_frames", "%"PRIu64, nb_streams_frames[stream_idx]);
--
1.8.5.3
More information about the ffmpeg-devel
mailing list