[vlc-devel] [PATCH 1/2] mp4 demux: ensure the PTS is set (to the DTS)

Rafaël Carré funman at videolan.org
Sun Nov 13 06:27:07 CET 2011


Also for videos (in case we didn't find the ctts box)
---
 modules/demux/mp4/mp4.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/modules/demux/mp4/mp4.c b/modules/demux/mp4/mp4.c
index 9561d0f..a9914e7 100644
--- a/modules/demux/mp4/mp4.c
+++ b/modules/demux/mp4/mp4.c
@@ -738,10 +738,8 @@ static int Demux( demux_t *p_demux )
                 i_delta = MP4_TrackGetPTSDelta( tk );
                 if( i_delta != -1 )
                     p_block->i_pts = p_block->i_dts + i_delta;
-                else if( tk->fmt.i_cat != VIDEO_ES )
-                    p_block->i_pts = p_block->i_dts;
                 else
-                    p_block->i_pts = VLC_TS_INVALID;
+                    p_block->i_pts = p_block->i_dts;
 
                 if( !tk->b_drms || ( tk->b_drms && tk->p_drms ) )
                     es_out_Send( p_demux->out, tk->p_es, p_block );
-- 
1.7.5.4



More information about the vlc-devel mailing list