[vlc-devel] commit: Remove non-sensical NPT c omputation code from c9569b35. ( Rémi Den is- Courmont )

Derk-Jan Hartman hartman at videolan.org
Tue Jul 22 23:42:44 CEST 2008


Ok, this is some debug from seeking into this stream (a good portion  
into the future).
There is a large difference in the times, and later a correction on  
that again. (but since the data is already in the chain, we see those  
packets dropped between the first and the second correction.)

This should not happen, clearly. I'm not sure what's going on here...

According to Ross, this cannot happen unless the stream is broken, but  
shouldn't QTP be affected by such large differences as well then?

DJ

[00000473] live555 demux debug: Diff for track avc1, is now: 66733
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000475] main decoder debug: End of video preroll
[00000473] live555 demux debug: Diff for track mp4a, is now: 4316257999
[00000473] live555 demux debug: tk->rtpSource- 
 >hasBeenSynchronizedUsingRTCP()
[00000473] live555 demux error: clock gap, setting p_sys->i_pcr to  
1216766637825999
[00000473] live555 demux error: Sending PCR 1216766637825999
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000474] main decoder debug: End of audio preroll
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 552322990
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 66733
[00000473] live555 demux debug: Diff for track avc1, is now: 33366
[00000473] live555 demux debug: Diff for track avc1, is now: 66733
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 552268000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000476] main audio output warning: computed PTS is out of range  
(114997), clearing out
[00000476] main audio output warning: output PTS is out of range  
(140636), clearing out
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000476] main audio output debug: audio output is starving (444635),  
playing silence
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000476] main audio output warning: output date isn't PTS date,  
requesting resampling (-60619)
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000476] main audio output warning: buffer is 60619 in advance,  
triggering downsampling
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -4870252824
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: -4869261999
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000473] live555 demux debug: Diff for track avc1, is now: -33366
[00000473] live555 demux debug: Diff for track mp4a, is now: 96000
[00000473] live555 demux debug: Diff for track avc1, is now: 100100
[00000476] main audio output warning: received buffer in the future  
(552703320)
[00000476] main audio output warning: received buffer in the future  
(552735112)
[00000476] main audio output warning: received buffer in the future  
(552766922)
[00000476] main audio output warning: received buffer in the future  
(552798730)
[00000476] main audio output warning: received buffer in the future  
(552830534)
[00000476] main audio output warning: received buffer in the future  
(552862352)
[00000476] main audio output warning: received buffer in the future  
(552894173)
[00000476] main audio output warning: received buffer in the future  
(552925957)
[00000476] main audio output warning: received buffer in the future  
(552957776)
[00000476] main audio output warning: received buffer in the future  
(552989597)
[00000476] main audio output warning: received buffer in the future  
(553021417)
[00000476] main audio output warning: received buffer in the future  
(553053237)
[00000476] main audio output warning: received buffer in the future  
(553085057)
[00000476] main audio output warning: received buffer in the future  
(553116675)
[00000476] main audio output warning: received buffer in the future  
(553148493)
[00000476] main audio output warning: received buffer in the future  
(553180315)
[00000476] main audio output warning: received buffer in the future  
(553212132)
[00000476] main audio output warning: received buffer in the future  
(553243948)
[00000476] main audio output warning: received buffer in the future  
(553275764)
[00000476] main audio output warning: received buffer in the future  
(553307586)


Note how we get some really weird values after some time (this is  
about 5-10 secs of debug)

On 22 jul 2008, at 18:23, Rémi Denis-Courmont wrote:
> Le lundi 21 juillet 2008 15:27:52 Ross Finlayson, vous avez écrit :
>> No - what you get from the RTP stream are presentation times, and
>> that is *all* you get from the RTP stream.  (Note, however, that
>> these presentation times are not necessarily monotonic - e.g., if the
>> stream is MPEG-2 streams with B-frames.)  These presentation times
>> were generated by the server's clock; *however*, there is no
>> guarantee that these times are aligned at all with the receiver's
>> 'wall-clock time'.  I.e., there is no guarantee that the server is
>> generating times that are in sync with 'real world time'.
>
> RTP timestamps are "derived from a clock that increments  
> monotonically and
> linearly in time to allow synchronization and jitter calculations".  
> Since the
> VLC clock also increments monotonically and linearly (at 1MHz).  
> Hence, let
> alone network jitter, the RTP timestamp and VLC clock are correlated  
> through
> an affine transformation. The whole point of the VLC input  
> synchronization is
> to estimate this transformation, and the jitter, and cache and  
> resample as
> required. For historical reasons, VLC uses the MPEG terminology  
> (PCR, PTS,
> DTS), but that's beyond the point.
>
> Furthermore, an RTSP server is supposed to scale the RTP timestamp  
> according
> to the RTP frequency and the RTSP Speed (1.0 by default), hence the  
> affine
> slope is bound to be close to 1, unless the hardware clock is  
> totally broken.
>
> In practice, VLC needs to use the RT*C*P timestamps as the reference  
> so that
> multiple RTP streams can be synchronized. But there is no assumption  
> about
> that being equal to the wall clock. In fact, most VLC demuxers start  
> counting
> the PTS from 0, rather than "current time". And the VLC clock starts  
> from an
> arbitrary point in the past (e.g. the system boot on Windows and  
> Linux).
>
>> (Even though the times included in RTCP reports are in the Network
>> Time Protocol (NTP) time *format*, they are not guaranteed to
>> actually be NTP-synced times.  This is apparently what is happening
>> with your QTSS stream, if you've found that the received presentation
>> times are not aligned with VLC's wall clock.)
>
> I have to disagree. Of course, there will be an arbitrary offset  
> between the
> RTCP timestamps, and the VLC clock. But the RTP timestamps and the  
> VLC clock
> will increase at almost the same speed (i.e. the slope of the affine
> transformation).



More information about the vlc-devel mailing list