History

avformat/dump: Print tbc value

Fixes regression of av_dump_format() Fixes part of Ticket 5444

Michael Niedermayer committed 10 years ago

Commit bb3388f1 parent d953b281 file · +7 −4Browse files

Showing the changes to libavformat/dump.c (1 of 1 file). Show all

Unified · Split

libavformat/dump.c+7−4
@@ -492,16 +492,19 @@ static void dump_stream_format(AVFormatContext *ic, int i, · 491 unmodified lines
492492 int fps = st->avg_frame_rate.den && st->avg_frame_rate.num;
493493 int tbr = st->r_frame_rate.den && st->r_frame_rate.num;
494494 int tbn = st->time_base.den && st->time_base.num;
495+ int tbc = st->codec->time_base.den && st->codec->time_base.num;
495496
496− if (fps || tbr || tbn)
497+ if (fps || tbr || tbn || tbc)
497498 av_log(NULL, AV_LOG_INFO, "%s", separator);
498499
499500 if (fps)
500− print_fps(av_q2d(st->avg_frame_rate), tbr || tbn ? "fps, " : "fps");
501+ print_fps(av_q2d(st->avg_frame_rate), tbr || tbn || tbc ? "fps, " : "fps");
501502 if (tbr)
502− print_fps(av_q2d(st->r_frame_rate), tbn ? "tbr, " : "tbr");
503+ print_fps(av_q2d(st->r_frame_rate), tbn || tbc ? "tbr, " : "tbr");
503504 if (tbn)
504− print_fps(1 / av_q2d(st->time_base), "tbn");
505+ print_fps(1 / av_q2d(st->time_base), tbc ? "tbn, " : "tbn");
506+ if (tbc)
507+ print_fps(1 / av_q2d(st->codec->time_base), "tbc");
505508 }
506509
507510 if (st->disposition & AV_DISPOSITION_DEFAULT)

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t