mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
alsa: htimestamp needs an operation to sync with hw
So use snd_pcm_avail
This commit is contained in:
parent
29e6544bae
commit
6b6f3432fe
1 changed files with 1 additions and 0 deletions
|
|
@ -1887,6 +1887,7 @@ static int get_avail(struct state *state, uint64_t current_time, snd_pcm_uframes
|
|||
snd_htimestamp_t tstamp;
|
||||
uint64_t then;
|
||||
|
||||
avail = snd_pcm_avail(state->hndl);
|
||||
if ((res = snd_pcm_htimestamp(state->hndl, &avail, &tstamp)) < 0) {
|
||||
if ((res = alsa_recover(state, res)) < 0)
|
||||
return res;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue