mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2026-02-15 22:05:18 -05:00
ucm: add ${find-card} and ${find-device} substitutions
It may be useful to find a correct card or device through
control API information fields.
Increase the syntax version to 4.
Examples:
${find-card:field=name,regex='HDA Intel'}
${find-device:type=pcm,field=id,regex='HDMI 1$'}
${find-device:ctl=hw:acp,type=pcm,field=id,regex=DMIC}
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:
parent
00eafe98ee
commit
296b067fc7
3 changed files with 335 additions and 7 deletions
|
|
@ -40,7 +40,7 @@
|
|||
#include <pthread.h>
|
||||
#include "use-case.h"
|
||||
|
||||
#define SYNTAX_VERSION_MAX 3
|
||||
#define SYNTAX_VERSION_MAX 4
|
||||
|
||||
#define MAX_CARD_SHORT_NAME 32
|
||||
#define MAX_CARD_LONG_NAME 80
|
||||
|
|
@ -289,6 +289,7 @@ int uc_mgr_open_ctl(snd_use_case_mgr_t *uc_mgr,
|
|||
int slave);
|
||||
|
||||
struct ctl_list *uc_mgr_get_master_ctl(snd_use_case_mgr_t *uc_mgr);
|
||||
struct ctl_list *uc_mgr_get_ctl_by_card(snd_use_case_mgr_t *uc_mgr, int card);
|
||||
struct ctl_list *uc_mgr_get_ctl_by_name(snd_use_case_mgr_t *uc_mgr,
|
||||
const char *name, int idx);
|
||||
snd_ctl_t *uc_mgr_get_ctl(snd_use_case_mgr_t *uc_mgr);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue