]> code.delx.au - pulseaudio/blob - src/modules/alsa-util.h
big s/polyp/pulse/g
[pulseaudio] / src / modules / alsa-util.h
1 #ifndef fooalsautilhfoo
2 #define fooalsautilhfoo
3
4 /* $Id$ */
5
6 /***
7 This file is part of PulseAudio.
8
9 PulseAudio is free software; you can redistribute it and/or modify
10 it under the terms of the GNU Lesser General Public License as published
11 by the Free Software Foundation; either version 2 of the License,
12 or (at your option) any later version.
13
14 PulseAudio is distributed in the hope that it will be useful, but
15 WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 General Public License for more details.
18
19 You should have received a copy of the GNU Lesser General Public License
20 along with PulseAudio; if not, write to the Free Software
21 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
22 USA.
23 ***/
24
25 #include <asoundlib.h>
26
27 #include <pulse/sample.h>
28 #include <pulse/mainloop-api.h>
29
30 #include <pulse/channelmap.h>
31
32 struct pa_alsa_fdlist;
33
34 struct pa_alsa_fdlist *pa_alsa_fdlist_new(void);
35 void pa_alsa_fdlist_free(struct pa_alsa_fdlist *fdl);
36
37 int pa_alsa_fdlist_init_pcm(struct pa_alsa_fdlist *fdl, snd_pcm_t *pcm_handle, pa_mainloop_api* m, void (*cb)(void *userdata), void *userdata);
38 int pa_alsa_fdlist_init_mixer(struct pa_alsa_fdlist *fdl, snd_mixer_t *mixer_handle, pa_mainloop_api* m);
39
40 int pa_alsa_set_hw_params(snd_pcm_t *pcm_handle, pa_sample_spec *ss, uint32_t *periods, snd_pcm_uframes_t *period_size);
41
42 int pa_alsa_prepare_mixer(snd_mixer_t *mixer, const char *dev);
43 snd_mixer_elem_t *pa_alsa_find_elem(snd_mixer_t *mixer, const char *name, const char *fallback);
44
45 #endif