[mythtv] Reasonable avsync at startup
Doug Larrick
doug at ties.org
Sun Aug 29 10:50:57 EDT 2004
Bruce Markey wrote:
> One thing it shows is a long standing problem (at least pre-0.6!)
> with the need to slew a lot at startup before audio and video
> come into sync. It would be great if you could look into this
> to help make the best possible DVR for all of us =).
>
> It seems that audio time and video time are initially set relative
> to the system clock. However, video is almost always way ahead
> of audio by tens of frames and has to wait for audio to catch up.
From some experimentation this morning, it appears that the issue here
is that when audioout comes out of pause, it still has to play the
soundcard's entire buffer (full of zeros) before it gets around to
playing the audio we just gave it. My soundcard has a 64k buffer, so
for normal audio that's just over half a second. The best fix would
probably be to clear out this buffer when coming out of audio pause;
alternatively video could wait until audio hits the target time until
unpausing.
-Doug
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
Url : http://mythtv.org/pipermail/mythtv-dev/attachments/20040829/6c43f114/signature.pgp
More information about the mythtv-dev
mailing list