summaryrefslogtreecommitdiffstats
path: root/libhb/decvobsub.c
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2009-06-13 17:40:29 +0000
committerjstebbins <[email protected]>2009-06-13 17:40:29 +0000
commit5a48476a05a18fbd5385aab24134c7d0c6b7b59d (patch)
tree938b2204a29b3eef445c2e4b77f97ceb08596850 /libhb/decvobsub.c
parentc9987f3bb7a178159687e53edc88bc55ccb5cfd3 (diff)
libhb: fix forced foreign language scan issues
- subtitles were not being added to list of subs to scan because the wrong config was being checked for the forced flag. needed to use job->select_subtitle_config instead of subtitle->config - scr code in reader was preventing the majority of subtitle packets from reaching decvobsub. made decvobsub more robust by adding ability to re-sync in the event of lost packets. made scr recovery initialize itself even in the event that it sees audio or subtitles before seeing video. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2526 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/decvobsub.c')
-rw-r--r--libhb/decvobsub.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/libhb/decvobsub.c b/libhb/decvobsub.c
index 2a5ccab01..c4474f9aa 100644
--- a/libhb/decvobsub.c
+++ b/libhb/decvobsub.c
@@ -98,6 +98,15 @@ int decsubWork( hb_work_object_t * w, hb_buffer_t ** buf_in,
pv->pts = in->start;
}
}
+ else
+ {
+ // bad size, must have lost sync
+ // force re-sync
+ if ( pv->buf != NULL )
+ hb_buffer_close( &pv->buf );
+ pv->size_sub = 0;
+ }
+
}
*buf_out = NULL;