mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-16 08:56:45 -05:00
alsa: use timerfd
Use timerfd instead of period events to wake up alsa. module-autolink: fix crash Some cleanups
This commit is contained in:
parent
c86673b557
commit
46928cbc04
8 changed files with 197 additions and 139 deletions
|
|
@ -136,8 +136,8 @@ struct _SpaALSAState {
|
|||
SpaAudioInfo current_format;
|
||||
uint8_t format_buffer[1024];
|
||||
|
||||
snd_pcm_sframes_t buffer_frames;
|
||||
snd_pcm_sframes_t period_frames;
|
||||
snd_pcm_uframes_t buffer_frames;
|
||||
snd_pcm_uframes_t period_frames;
|
||||
snd_pcm_format_t format;
|
||||
int rate;
|
||||
int channels;
|
||||
|
|
@ -161,6 +161,9 @@ struct _SpaALSAState {
|
|||
int n_fds;
|
||||
struct pollfd fds[16];
|
||||
SpaSource sources[16];
|
||||
int timerfd;
|
||||
bool alsa_started;
|
||||
int threshold;
|
||||
|
||||
int64_t sample_count;
|
||||
int64_t last_ticks;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue