alsa-ucm: Use playback/capture rate specification from UCM

Add new PlaybackRate/CaptureRate values for UCM that can be used to
specify custom rates for devices. This value can either be set on the
verb, which makes it apply to all devices, or on the device to override
the verb setting.
This commit is contained in:
Arun Raghavan 2013-08-07 22:56:58 +05:30
parent 6a6ee8fd22
commit 4d638b5ffd
2 changed files with 36 additions and 2 deletions

View file

@ -56,6 +56,9 @@ typedef void snd_use_case_mgr_t;
/** For devices: Playback priority */
#define PA_ALSA_PROP_UCM_PLAYBACK_PRIORITY "alsa.ucm.playback.priority"
/** For devices: Playback rate */
#define PA_ALSA_PROP_UCM_PLAYBACK_RATE "alsa.ucm.playback.rate"
/** For devices: Playback channels */
#define PA_ALSA_PROP_UCM_PLAYBACK_CHANNELS "alsa.ucm.playback.channels"
@ -71,6 +74,9 @@ typedef void snd_use_case_mgr_t;
/** For devices: Capture priority */
#define PA_ALSA_PROP_UCM_CAPTURE_PRIORITY "alsa.ucm.capture.priority"
/** For devices: Capture rate */
#define PA_ALSA_PROP_UCM_CAPTURE_RATE "alsa.ucm.capture.rate"
/** For devices: Capture channels */
#define PA_ALSA_PROP_UCM_CAPTURE_CHANNELS "alsa.ucm.capture.channels"
@ -123,6 +129,9 @@ struct pa_alsa_ucm_device {
unsigned playback_priority;
unsigned capture_priority;
unsigned playback_rate;
unsigned capture_rate;
unsigned playback_channels;
unsigned capture_channels;