diff options
author | jstebbins <[email protected]> | 2011-04-02 20:17:14 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2011-04-02 20:17:14 +0000 |
commit | 9ef1bf3c81bab338d04f712016147a9e7aad2fbe (patch) | |
tree | 398927ebb40076d04225c77ceded015be8566dce /libhb/muxmp4.c | |
parent | de2144f7054a3a106164a5356a9ee989674160b1 (diff) |
Shorten instead of dropping overlapping subtitles in mp4
If the non-overlaping remainder is greater than 0.5 seconds, shorten
the subtitle instead of completely dropping it.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3897 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/muxmp4.c')
-rw-r--r-- | libhb/muxmp4.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libhb/muxmp4.c b/libhb/muxmp4.c index e206f3c13..b1148819a 100644 --- a/libhb/muxmp4.c +++ b/libhb/muxmp4.c @@ -1111,6 +1111,16 @@ static int MP4Mux( hb_mux_object_t * m, hb_mux_data_t * mux_data, code should coalesce overlapping subtitle lines. */ if( buf->start < mux_data->sum_dur ) { + if ( buf->stop - mux_data->sum_dur > 90*500 ) + { + hb_log("MP4Mux: shortening overlapping subtitle, " + "start %"PRId64", stop %"PRId64", sum_dur %"PRId64, + buf->start, buf->stop, m->sum_dur); + buf->start = mux_data->sum_dur; + } + } + if( buf->start < mux_data->sum_dur ) + { hb_log("MP4Mux: skipping overlapping subtitle, " "start %"PRId64", stop %"PRId64", sum_dur %"PRId64, buf->start, buf->stop, m->sum_dur); |