[vlc-devel] [PATCH] MKV: use the more accurate i_pcr for GET_TIME and GET_POSITION
Francois Cartegnie
fcvlcdev at free.fr
Thu Mar 12 18:26:22 CET 2015
Le 12/03/2015 15:42, Steve Lhomme a écrit :
> pf = (double*)va_arg( args, double * );
> if ( p_sys->f_duration > 0.0 )
> - *pf = (double)(p_sys->i_pts >= p_sys->i_start_pts ? p_sys->i_pts : p_sys->i_start_pts ) / (1000.0 * p_sys->f_duration);
> + *pf = (double)(p_sys->i_pcr >= p_sys->i_start_pts ? p_sys->i_pcr : p_sys->i_start_pts ) / (1000.0 * p_sys->f_duration);
You'll have a dancing position within the first PCR interval.
Start PCR < Start PTS -> uses PCR (total duration includes 1st PCR->1st
pts range)
then at some point, for subsequent calls
PCR always > Start PTS -> uses PTS (total duration excludes 1st PCR->1st
pts range)
Francois
More information about the vlc-devel
mailing list