Sasi Inguva 93db5e3fc4 lavf/mov.c: offset index timestamps by the minimum pts to make first pts zero
If the videos starts with B frame, then the minimum composition time
as computed by stts + ctts will be non-zero. Hence we need to shift
the DTS, so that the first pts is zero. This was the intention of that
code-block. However it was subtracting by the wrong amount.

For example, for one of the videos in the bug nonFormatted.mp4 we have

stts:
sample_count  duration
960           1001

ctts:
sample_count  duration
1             3003
2             0
1             3003
....

The resulting composition times are :  3003, 1001, 2002, 6006, ...

The minimum composition time or PTS is 1001, which should be used to
offset DTS. However the code block was wrongly using ctts[0] which is
3003. Hence the PTS was negative. This change computes the minimum pts
encountered while fixing the index, and then subtracts it from all the
timestamps after the edit list fixes are applied.

Samples files available from:

https://bugs.chromium.org/p/chromium/issues/detail?id=721451
https://bugs.chromium.org/p/chromium/issues/detail?id=723537

fate-suite/h264/twofields_packet.mp4 is a similar file starting with 2
B frames. Before this change the PTS of first two B-frames was -6006
and -3003, and I am guessing one of them got dropped when being decoded
and remuxed  to the framecrc before, and now it is not being dropped.

Signed-off-by: Sasi Inguva <isasi@google.com>
2017-06-09 18:13:33 +02:00
..
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-18 22:43:58 +02:00
2016-04-13 11:37:14 -03:00
aic
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
amv
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
ast
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
caf
2016-10-01 17:22:22 +02:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
crc
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-02-01 12:12:15 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-26 16:30:04 -04:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-08-21 02:58:13 +02:00
2016-04-13 11:37:14 -03:00
dpx
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-08-22 22:07:48 +02:00
2016-04-13 11:37:14 -03:00
2016-05-28 22:09:17 +02:00
2016-09-09 12:49:15 +02:00
2016-04-13 11:37:14 -03:00
2016-09-09 00:57:01 +02:00
2016-09-09 12:49:15 +02:00
2016-09-09 11:55:45 +02:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-03-09 20:05:29 +01:00
2016-04-13 11:37:14 -03:00
2016-12-10 22:24:10 +01:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-09-04 12:05:06 +02:00
2016-09-04 20:28:29 +02:00
jv
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
m4v
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
md5
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2017-03-17 13:12:25 -04:00
2016-10-01 17:22:22 +02:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-20 00:02:30 +02:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
opt
2015-11-07 16:04:09 +01:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
ptx
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
rl2
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
sha
smc
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2017-01-27 17:06:42 +01:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-10-01 17:22:22 +02:00
2016-04-13 11:37:14 -03:00
tea
thp
2016-04-13 11:37:14 -03:00
2017-05-25 14:30:04 +02:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
url
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
vb
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
vp7
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
w64
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
yop
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00
2016-04-13 11:37:14 -03:00