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

Steve Lhomme robux4 at videolabs.io
Fri Mar 13 15:10:40 CET 2015


On Fri, Mar 13, 2015 at 3:08 PM, Francois Cartegnie <fcvlcdev at free.fr> wrote:
> 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 ?

Use a value that's adjusted to be incremental and within proper
boundaries, unlike the pts which can be incoherent depending on the
interleaving quality.

Steve



More information about the vlc-devel mailing list