[alsa-devel] XRUN handling
melwyn lobo
linux.melwyn at gmail.com
Tue Jul 6 07:03:57 CEST 2010
Hi all,
I have noticed when an Xrun occurs, the bytes between the hw_ptr and
appl_ptr are not copied when both hw and appl pointers are reset in
snd_pcm_prepare().
Consider the following parameters:
buffer_size : 22352
period_size : 1016
period_time : 23038
tstamp_mode : NONE
period_step : 1
avail_min : 1016
period_event : 0
start_threshold : 22352
stop_threshold : 22352
silence_threshold: 0
silence_size : 0
In case snd_pcm_playback_avail() is less than stop threshold but
greater than 0, then these bytes are missing after Xrun prepare and
start stage.
Is my analysis correct? If so how do we ensure correct behaviour ie
byte accuracy after Xrun.
Thanks,
M.
More information about the Alsa-devel
mailing list