[vlc-devel] [PATCH] MKV: use the more accurate i_pcr for GET_TIME and GET_POSITION

Francois Cartegnie fcvlcdev at free.fr
Fri Mar 13 15:08:02 CET 2015


Le 13/03/2015 10:31, Steve Lhomme a écrit :
> On Thu, Mar 12, 2015 at 6:26 PM, Francois Cartegnie <fcvlcdev at free.fr> wrote:
>> 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.
> 
> I think we can live with that. the GET_POSITION is not meant to be
> absolutely precise.

"Subject" of this patch ?

>> Start PCR < Start PTS -> uses PCR (total duration includes 1st PCR->1st
>> pts range)
> 
> I don't understand. It will always use i_start_pts until there's a
> value that indicate we passed the "preroll" data. And i_pcr can never
> be bigger than i_pts or i_dts.

I've never said any dts/pts.

Francois




More information about the vlc-devel mailing list