[vlc-devel] [PATCH 11/17] dvdnav: handle matching_time

Steve Lhomme robux4 at ycbcr.xyz
Wed Mar 10 07:19:04 UTC 2021


On 2021-03-09 16:15, Thomas Guillem wrote:
> ---
>   modules/access/dvdnav.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/modules/access/dvdnav.c b/modules/access/dvdnav.c
> index 29170ae832c..a62c3b0399b 100644
> --- a/modules/access/dvdnav.c
> +++ b/modules/access/dvdnav.c
> @@ -1500,7 +1500,8 @@ static int DemuxBlock( demux_t *p_demux, const uint8_t *p, int len )
>               if( !ps_pkt_parse_pack( p_pkt->p_buffer, p_pkt->i_buffer,
>                                       &i_scr, &i_mux_rate ) )
>               {
> -                es_out_SetPCR( p_sys->p_tf_out, i_scr );
> +                es_out_SetPCRTime( p_sys->p_tf_out, i_scr,
> +                                   dvdnav_get_current_time( p_sys->dvdnav ) * 100 / 9 );

You should use FROM_SCALE_NZ() for the conversion or FROM_SCALE() if you 
don't want it to be invalid and need the shift.

>                   if( i_mux_rate > 0 ) p_sys->i_mux_rate = i_mux_rate;
>               }
>               block_Release( p_pkt );
> -- 
> 2.30.0
> 
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
> 


More information about the vlc-devel mailing list