diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2015-03-19 13:26:44 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2015-03-19 13:26:47 +0100 |
commit | 25d7e3ad594a8b5ed1b840d75185df34efdde6ad (patch) | |
tree | fc24fcd728f6a81ff8f4050018b45a6e2db41178 | |
parent | 3602782429ef3fceafd78c52014088655e4256a4 (diff) | |
parent | 5c337353a2546416631a87de4881850d99141c39 (diff) | |
download | ffmpeg-25d7e3ad594a8b5ed1b840d75185df34efdde6ad.tar.gz |
Merge commit '5c337353a2546416631a87de4881850d99141c39'
* commit '5c337353a2546416631a87de4881850d99141c39':
movenc: Move sidx edit list timestamp adjustment into a block
Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavformat/movenc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c index ef8a1d2d73..d4c3222e9e 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -3652,15 +3652,15 @@ static int mov_write_sidx_tag(AVIOContext *pb, duration = track->start_dts + track->track_duration - track->cluster[0].dts; starts_with_SAP = track->cluster[0].flags & MOV_SYNC_SAMPLE; + + // pts<0 should be cut away using edts + if (presentation_time < 0) + presentation_time = 0; } else { entries = track->nb_frag_info; presentation_time = track->frag_info[0].time; } - // pts<0 should be cut away using edts - if (presentation_time < 0) - presentation_time = 0; - avio_wb32(pb, 0); /* size */ ffio_wfourcc(pb, "sidx"); avio_w8(pb, 1); /* version */ |