Commit c095b59a authored by Gildas Bazin's avatar Gildas Bazin

* modules/codec/ffmpeg/video.c: temporary hack to work around demuxers that set the DTS value in p_pes->i_pts.
* modules/demux/ogg.c: don't try anymore to send interpolated pts to ffmpeg.
parent 7fb2bf9a
......@@ -2,7 +2,7 @@
* video.c: video decoder using ffmpeg library
*****************************************************************************
* Copyright (C) 1999-2001 VideoLAN
* $Id: video.c,v 1.37 2003/08/08 17:08:32 gbazin Exp $
* $Id: video.c,v 1.38 2003/08/09 19:49:13 gbazin Exp $
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr>
* Gildas Bazin <gbazin@netcourrier.com>
......@@ -585,8 +585,12 @@ usenextdata:
p_pic = (picture_t *)p_vdec->p_ff_pic->opaque;
}
/* Set the PTS */
if( p_vdec->p_ff_pic->pts )
/* Set the PTS
* There is an ugly hack here because some demuxers pass us a dts instead
* of a pts so this screw up things for streams with B frames. */
if( p_vdec->p_ff_pic->pts &&
( !p_vdec->p_context->has_b_frames ||
p_vdec->p_ff_pic->pict_type == FF_B_TYPE ) )
{
p_vdec->pts = p_vdec->p_ff_pic->pts;
}
......
......@@ -2,7 +2,7 @@
* ogg.c : ogg stream input module for vlc
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: ogg.c,v 1.29 2003/07/09 22:10:13 gbazin Exp $
* $Id: ogg.c,v 1.30 2003/08/09 19:49:13 gbazin Exp $
*
* Authors: Gildas Bazin <gbazin@netcourrier.com>
*
......@@ -421,7 +421,8 @@ static void Ogg_DecodePacket( input_thread_t *p_input,
p_data->p_payload_end = p_data->p_payload_start + p_oggpacket->bytes;
/* Convert the pcr into a pts */
if( p_stream->i_cat != SPU_ES )
if( p_stream->i_fourcc == VLC_FOURCC( 'v','o','r','b' ) ||
p_stream->i_fourcc == VLC_FOURCC( 't','h','e','o' ) )
{
p_pes->i_pts = ( p_stream->i_pcr < 0 ) ? 0 :
input_ClockGetTS( p_input, p_input->stream.p_selected_program,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment