vlc | branch: master | Francois Cartegnie <[email protected]> | Tue May 28 13:08:36 2019 +0200| [fd2cea6fb4de954e073c9e76e8463021ec5fe527] | committer: Francois Cartegnie
demux: ts: create define for generated PCR offset > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fd2cea6fb4de954e073c9e76e8463021ec5fe527 --- modules/demux/mpeg/ts.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/demux/mpeg/ts.c b/modules/demux/mpeg/ts.c index 69843bc1db..93009d487a 100644 --- a/modules/demux/mpeg/ts.c +++ b/modules/demux/mpeg/ts.c @@ -207,6 +207,7 @@ static void PCRFixHandle( demux_t *, ts_pmt_t *, block_t * ); #define PROBE_MAX (PROBE_CHUNK_COUNT * 10) #define BLOCK_FLAG_SOURCE_RANDOM_ACCESS (1 << BLOCK_FLAG_PRIVATE_SHIFT) +#define GENERATED_PCR_DPB_OFFSET VLC_TICK_FROM_MS(120) static int DetectPacketSize( demux_t *p_demux, unsigned *pi_header_size, int i_offset ) { @@ -1672,8 +1673,8 @@ static void ParsePESDataChain( demux_t *p_demux, ts_pid_t *pid, block_t *p_pes ) if ( p_pmt->pcr.b_disable && p_block->i_dts != VLC_TICK_INVALID && ( p_pmt->i_pid_pcr == pid->i_pid || p_pmt->i_pid_pcr == 0x1FFF ) ) { - stime_t i_pcr = ( p_block->i_dts > VLC_TICK_FROM_MS(120) ) - ? TO_SCALE(p_block->i_dts - VLC_TICK_FROM_MS(120)) + stime_t i_pcr = ( p_block->i_dts > GENERATED_PCR_DPB_OFFSET ) + ? TO_SCALE(p_block->i_dts - GENERATED_PCR_DPB_OFFSET) : TO_SCALE(p_block->i_dts); ProgramSetPCR( p_demux, p_pmt, i_pcr ); } _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
