}
vout_ShowTextAbsolute( p_vout, psz_subtitle, NULL,
- OSD_ALIGN_BOTTOM | p_sys->i_align,
- i_align_h, i_align_v,
- p_block->i_pts, p_block->i_dts );
+ OSD_ALIGN_BOTTOM | p_sys->i_align, i_align_h,
+ i_align_v, p_block->i_pts,
+ p_block->i_length ? p_block->i_pts + p_block->i_length : 0 );
free( psz_subtitle );
}
}
else
{
- es_out_Control( p_demux->out, ES_OUT_SET_PCR, p_stream->i_pcr );
+ es_out_Control( p_demux->out, ES_OUT_SET_PCR,
+ p_stream->i_pcr );
}
continue;
}
ogg_sync_reset( &p_sys->oy );
default:
- return demux2_vaControlHelper( p_demux->s,
- 0, -1,
- p_sys->i_bitrate, 1, i_query, args );
+ return demux2_vaControlHelper( p_demux->s, 0, -1, p_sys->i_bitrate,
+ 1, i_query, args );
}
}
/* 1 frame per packet */
p_stream->i_interpolated_pcr += (I64C(1000000) / p_stream->f_rate);
else if( p_stream->fmt.i_bitrate )
- p_stream->i_interpolated_pcr += ( p_oggpacket->bytes * I64C(1000000)
- / p_stream->fmt.i_bitrate / 8 );
+ p_stream->i_interpolated_pcr +=
+ ( p_oggpacket->bytes * I64C(1000000) /
+ p_stream->fmt.i_bitrate / 8 );
}
}
{
/* Set correct starting date in header packets */
p_stream->p_packets_backup[i].granulepos =
- p_stream->i_interpolated_pcr * p_stream->f_rate / I64C(1000000);
+ p_stream->i_interpolated_pcr * p_stream->f_rate /
+ I64C(1000000);
Ogg_DecodePacket( p_demux, p_stream,
&p_stream->p_packets_backup[i] );
es_out_Control( p_demux->out, ES_OUT_RESET_PCR );
/* Call the pace control */
- es_out_Control( p_demux->out, ES_OUT_SET_PCR, p_stream->i_pcr );
+ es_out_Control( p_demux->out, ES_OUT_SET_PCR,
+ p_stream->i_pcr );
}
p_stream->i_previous_pcr = p_stream->i_pcr;
p_block->i_dts = p_block->i_pts = i_pts;
else if( p_stream->fmt.i_cat == SPU_ES )
{
- p_block->i_pts = i_pts;
- p_block->i_dts = 0;
+ p_block->i_dts = p_block->i_pts = i_pts;
+ p_block->i_length = 0;
}
else if( p_stream->fmt.i_codec == VLC_FOURCC( 't','h','e','o' ) )
p_block->i_dts = p_block->i_pts = i_pts;
p_oggpacket->packet[i_header_len + 1] != '\n' &&
p_oggpacket->packet[i_header_len + 1] != '\r' ) )
{
- p_block->i_dts = p_block->i_pts + (mtime_t)lenbytes * 1000;
+ p_block->i_length = (mtime_t)lenbytes * 1000;
}
}
}
p_block->i_pts = p_sub->subtitle[p_sub->i_subtitle].i_start;
- p_block->i_dts = 0;
+ p_block->i_dts = p_block->i_pts;
if( p_sub->subtitle[p_sub->i_subtitle].i_stop > 0 )
{
- /* FIXME kludge i_dts means end of display... */
- p_block->i_dts = p_sub->subtitle[p_sub->i_subtitle].i_stop;
+ p_block->i_length =
+ p_sub->subtitle[p_sub->i_subtitle].i_stop - p_block->i_pts;
}
- memcpy( p_block->p_buffer, p_sub->subtitle[p_sub->i_subtitle].psz_text, i_len );
+ memcpy( p_block->p_buffer,
+ p_sub->subtitle[p_sub->i_subtitle].psz_text, i_len );
if( p_block->i_pts > 0 )
{
es_out_Send( p_input->p_es_out, p_sub->p_es, p_block );
/* FIXME i_spu == determines which of the spu tracks we will show. */
if( p_demux->p_es && i_spu == 0 )
{
- p_pkt->i_pts = p_bk->i_pts;
- p_pkt->i_dts = 0;
+ p_pkt->i_dts = p_pkt->i_pts = p_bk->i_pts;
+ p_pkt->i_length = 0;
es_out_Send( p_demux->p_input->p_es_out, p_demux->p_es, p_pkt );
p_bk->i_pts = 0; /* only first packet has a pts */