summaryrefslogtreecommitdiffstats
path: root/libhb/muxmp4.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2011-11-15 21:36:45 +0000
committerjstebbins <[email protected]>2011-11-15 21:36:45 +0000
commit935fe113ea0008656f4dfec80be731fd6d6c25d1 (patch)
treeca6be6e6969f820d95d33b46e462f923c8402175 /libhb/muxmp4.c
parentc557fe3d54da7141e898aae7f57f9897d92ba64c (diff)
Make sure decvobsub.c generates valid timestamps
sync.c expects that timestamps will all be resolved by the time buffers reach it. Reader will invalidate timestamps while waiting to resynchronize the SCR. So decoders (inparticular decvobsub) need to extrapolate timestamps when they are not supplied. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4352 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/muxmp4.c')
-rw-r--r--libhb/muxmp4.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/libhb/muxmp4.c b/libhb/muxmp4.c
index 5234c5a7a..d03326b80 100644
--- a/libhb/muxmp4.c
+++ b/libhb/muxmp4.c
@@ -1106,6 +1106,9 @@ static int MP4Mux( hb_mux_object_t * m, hb_mux_data_t * mux_data,
{
int64_t duration;
+ if( buf->start < 0 )
+ buf->start = mux_data->sum_dur;
+
if( buf->stop < 0 )
duration = 90000L * 10;
else
@@ -1175,6 +1178,9 @@ static int MP4Mux( hb_mux_object_t * m, hb_mux_data_t * mux_data,
{
int64_t duration;
+ if( buf->start < 0 )
+ buf->start = mux_data->sum_dur;
+
if( buf->stop < 0 )
duration = 90000L * 10;
else