[Libav-user] Container duration
Yuriy Pryyma
priymayuriy at gmail.com
Fri Feb 16 17:56:30 EET 2018
I have some question regarding duration
1)Why we are adding "magic" 5000 to AVFormatContext duration in
av_dump_format function?
See here
https://github.com/FFmpeg/FFmpeg/blob/9b79c65ec06f2bbe4f44c615b9df70db23126250/libavformat/dump.c#L576
2) How to set container duration longer then stream duration? Because as
I understand it is deduced from streams durations
3) How duration is calculated if stream have not zero start
time(frame.pts > 0). So stream start 1 second afther beginning and have
duration 2 seconds. So video will have duration 3 seconds? But if using
example muxing.c I set ost->frame->pts = 60 + ost->next_pts++. Duration
was the same(tested with avprobe) but video actually played longer then
10 seconds.
More information about the Libav-user
mailing list