summaryrefslogtreecommitdiffstats
path: root/libhb/demuxmpeg.c
diff options
context:
space:
mode:
Diffstat (limited to 'libhb/demuxmpeg.c')
-rw-r--r--libhb/demuxmpeg.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libhb/demuxmpeg.c b/libhb/demuxmpeg.c
index 4185cb503..763f3e31a 100644
--- a/libhb/demuxmpeg.c
+++ b/libhb/demuxmpeg.c
@@ -218,6 +218,14 @@ int hb_demux_ts( hb_buffer_t *buf_ps, hb_list_t *list_es, hb_psdemux_t *state )
{
if ( state )
{
+ if ( buf_ps->discontinuity )
+ {
+ // Buffer has been flagged as a discontinuity. This happens
+ // when a blueray changes clips.
+ ++state->scr_changes;
+ state->last_scr = buf_ps->start;
+ }
+
// we're keeping track of timing (i.e., not in scan)
// check if there's a new pcr in this packet
if ( buf_ps->stop >= 0 )