[vlc-devel] (hopefully) simple question on stream clocking

John Michael Zorko j.zorko at att.net
Mon Sep 8 00:36:54 CEST 2003

Hello, all ...

After implementing the TS discontinuity indicator setting code, and 
resetting the decoders on the client when this bit is detected in the 
TS packet, and making sure I seek to an E0 packet (video ES) with a 
sequence header, 95% of the macroblocking artifacts I see on the client 
when the server VLC does a seek on the stream are gone.  The few that 
are left may be due to open GOPs, but i'll worry about that later.  
Thanks to everyone who posted hints on how to do this -- it's 

Now, i've a (hopefully) simple question ... sometimes the client VLC 
stops updating the video after the server VLC seeks.  I've verified 
that the server VLC seeked to where I wanted it to (the E0 PES packet 
with a sequence header).  Sometimes it recovers after a second or two, 
sometimes it takes far longer (10-20 seconds), sometimes never.  This 
is sometimes accompanied by the infamous "decoder stuck" message, which 
implies that the vout thread is the culprit i.e. perhaps on an mwait() 
waiting to display a frame.  On the server, all it does is call 
input_Seek() to the position I want, then set the TS discontinuity 
indicator.  I don't do anything different with the PTS i.e. the TS 
muxer does what it always did, it just sets the TS discontinuity 
indicator when it should now.

The client, when it sees the TS discontinuity indicator on, does 
input_EscapeDiscontinuity() -- nothing else special.  Yet sometimes 
(after a lot of seeking on the server), the vout thread hangs.  Does 
the server VLC need to do something special to the PTS after a seek, 
something that it normally doesn't need to do?



Falling You - exploring the beauty of voice and sound
New EP, "hope thrown down," available now at

This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html
If you are in trouble, please contact <postmaster at videolan.org>

More information about the vlc-devel mailing list