http://bugs.winehq.org/show_bug.cgi?id=27937
--- Comment #7 from Raymond superquad.vortex2@gmail.com 2011-09-24 18:28:18 CDT --- Created attachment 36537 --> http://bugs.winehq.org/attachment.cgi?id=36537 Test playback/capture position
(In reply to comment #1)
After playing for 1 second, GetPosition cannot be farther than nSamplesPerSec. The bug in Wine is that it's based on snd_pcm_avail_update, which is about buffer space, instead of snd_pcm_delay.
With dmix, it's funny that GetPosition is initially too far ahead but then calms down (see below). That's because there's no further buffering.
With PulseAudio, GetPosition yields values far away in the future. That alone explains why any app that tries to sync audio and video creates a huge lag. It's not the fault of PulseAudio.
pulse plugin seem only update pointer at the selected period time.
so the playback/capture position is less inaccurate than those plug:dmix or hw for hda-intel
you can use the attach program to print the playback/capture position of different device (e.g. hw, plug:dmix, pulse, plughw, plug:jack)
alsa_test device dir rate periods stop_at_underrun silence