diff options
author | Gaullier Nicolas <nicolas.gaullier@arkena.com> | 2014-05-14 16:25:13 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-05-16 15:33:20 +0200 |
commit | 5d944f58db99d9481321a924fde62c1df385adca (patch) | |
tree | 627f30b1171f5092a06e4b74594926969cdc6cad | |
parent | 85349d8d00fd117414d47decdd652c1b84a2de63 (diff) | |
download | ffmpeg-5d944f58db99d9481321a924fde62c1df385adca.tar.gz |
estimate_timings_from_pts: Also consider packet duration
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index fd717b15c2..10ffb843bf 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -2515,7 +2515,7 @@ static void estimate_timings_from_pts(AVFormatContext *ic, int64_t old_offset) if (pkt->pts != AV_NOPTS_VALUE && (st->start_time != AV_NOPTS_VALUE || st->first_dts != AV_NOPTS_VALUE)) { - duration = end_time = pkt->pts; + duration = end_time = pkt->pts + pkt->duration; if (st->start_time != AV_NOPTS_VALUE) duration -= st->start_time; else |