mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2026-02-15 22:05:22 -05:00
alsa-ucm: Let profiles know their associated UCM verb
Currently each UCM verb generates one profile named the same as the verb, meaning it's trivial to know which verb the profile belongs to. This will be slightly harder to do when we generate multiple profiles per UCM verb (e.g. to make use of conflicting devices). It would still be possible to parse the profile name to get the UCM verb, but instead let's keep track of the struct instance representing the profile's associated verb. This also lets us remove a block of code searching for the verb by its name. Co-authored-by: Jaroslav Kysela <perex@perex.cz> [Alper: Reused Jaroslav's UCM profile context changes for UCM verb instead of combined devices.] Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com> Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/596>
This commit is contained in:
parent
880ff393f1
commit
9fc7064b9a
3 changed files with 16 additions and 14 deletions
|
|
@ -140,6 +140,7 @@ typedef struct pa_alsa_ucm_modifier pa_alsa_ucm_modifier;
|
|||
typedef struct pa_alsa_ucm_device pa_alsa_ucm_device;
|
||||
typedef struct pa_alsa_ucm_config pa_alsa_ucm_config;
|
||||
typedef struct pa_alsa_ucm_mapping_context pa_alsa_ucm_mapping_context;
|
||||
typedef struct pa_alsa_ucm_profile_context pa_alsa_ucm_profile_context;
|
||||
typedef struct pa_alsa_ucm_port_data pa_alsa_ucm_port_data;
|
||||
typedef struct pa_alsa_ucm_volume pa_alsa_ucm_volume;
|
||||
|
||||
|
|
@ -265,6 +266,10 @@ struct pa_alsa_ucm_mapping_context {
|
|||
pa_idxset *ucm_modifiers;
|
||||
};
|
||||
|
||||
struct pa_alsa_ucm_profile_context {
|
||||
pa_alsa_ucm_verb *verb;
|
||||
};
|
||||
|
||||
struct pa_alsa_ucm_port_data {
|
||||
pa_alsa_ucm_config *ucm;
|
||||
pa_device_port *core_port;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue