File: pcm_ext_parm.h

package info (click to toggle)
alsa-lib 1.1.3-5
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 8,656 kB
  • sloc: ansic: 84,132; sh: 11,192; makefile: 711
file content (41 lines) | stat: -rw-r--r-- 1,394 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
/* hw_params */
struct snd_ext_parm {
	unsigned int min, max;
	unsigned int num_list;
	unsigned int *list;
	unsigned int active: 1;
	unsigned int integer: 1;
};

static inline snd_mask_t *hw_param_mask(snd_pcm_hw_params_t *params,
					snd_pcm_hw_param_t var)
{
	return &params->masks[var - SND_PCM_HW_PARAM_FIRST_MASK];
}

static inline snd_interval_t *hw_param_interval(snd_pcm_hw_params_t *params,
						snd_pcm_hw_param_t var)
{
	return &params->intervals[var - SND_PCM_HW_PARAM_FIRST_INTERVAL];
}

/* make local functions really local */
#define snd_ext_parm_set_minmax \
	snd1_ext_parm_set_minmax
#define snd_ext_parm_set_list \
	snd1_ext_parm_set_list
#define snd_ext_parm_clear \
	snd1_ext_parm_clear
#define snd_interval_list \
	snd1_interval_list
#define snd_ext_parm_interval_refine \
	snd1_ext_parm_interval_refine
#define snd_ext_parm_mask_refine \
	snd1_ext_parm_mask_refine

int snd_ext_parm_set_minmax(struct snd_ext_parm *parm, unsigned int min, unsigned int max);
int snd_ext_parm_set_list(struct snd_ext_parm *parm, unsigned int num_list, const unsigned int *list);
void snd_ext_parm_clear(struct snd_ext_parm *parm);
int snd_interval_list(snd_interval_t *ival, int num_list, unsigned int *list);
int snd_ext_parm_interval_refine(snd_interval_t *ival, struct snd_ext_parm *parm, int type);
int snd_ext_parm_mask_refine(snd_mask_t *mask, struct snd_ext_parm *parm, int type);