diff options
author | Gaullier Nicolas <nicolas.gaullier@arkena.com> | 2014-05-14 20:25:13 +0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-05-16 17:33:20 +0400 |
commit | 5d944f58db99d9481321a924fde62c1df385adca (patch) | |
tree | 627f30b1171f5092a06e4b74594926969cdc6cad /libavformat/utils.c | |
parent | 85349d8d00fd117414d47decdd652c1b84a2de63 (diff) |
estimate_timings_from_pts: Also consider packet duration
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/utils.c')
-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 |