aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/alsa/alsa-softmixer.h
diff options
context:
space:
mode:
authorThierry Bultel <thierry.bultel@iot.bzh>2019-02-13 14:32:14 +0100
committerThierry Bultel <thierry.bultel@iot.bzh>2019-05-13 13:55:58 +0200
commit293fe6981f55aff68e42b668a565c5db65cc8468 (patch)
treea76f8b9588d1c5ad4ffad28be87679e7fd020cf1 /plugins/alsa/alsa-softmixer.h
parente355716f6bac57615195333559a746e283e22060 (diff)
core pcm: use the same model for writing and reading audio
Reading sound frames relies on usage of poll before calling snd_pcm_writei Recent seeks for bugs and CPU load issues have shown that the same thing must be done on the write side. Thus this commit uses the same mechanism, including the dedicated event pipe for the thread termination. Change-Id: Ifd5407c9e27da7801623583a6f7d4a2e845b43ea Signed-off-by: Thierry Bultel <thierry.bultel@iot.bzh>
Diffstat (limited to 'plugins/alsa/alsa-softmixer.h')
-rw-r--r--plugins/alsa/alsa-softmixer.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/plugins/alsa/alsa-softmixer.h b/plugins/alsa/alsa-softmixer.h
index 781411d..7b98b5b 100644
--- a/plugins/alsa/alsa-softmixer.h
+++ b/plugins/alsa/alsa-softmixer.h
@@ -158,8 +158,11 @@ typedef struct {
int tid;
char* info;
- int nbPcmFds;
- struct pollfd * pollFds;
+ int nbPcmFdsIn;
+ struct pollfd * pollFdsIn;
+
+ int nbPcmFdsOut;
+ struct pollfd * pollFdsOut;
sem_t sem;
pthread_mutex_t mutex;