Pass channelmask around and use it to name ports

Use the channel name in the port names of the dsp
This commit is contained in:
Wim Taymans 2018-09-11 18:09:45 +02:00
parent 7aae01fe15
commit fb3379e587
9 changed files with 217 additions and 15 deletions

View file

@ -86,6 +86,7 @@ static void *create_object(void *_data,
struct pw_client *client;
struct pw_node *dsp;
int res, channels, rate, maxbuffer;
uint64_t channelmask;
const char *str;
enum pw_direction direction;
struct node_data *nd;
@ -106,6 +107,11 @@ static void *create_object(void *_data,
channels = pw_properties_parse_int(str);
if ((str = pw_properties_get(properties, "audio-dsp.channelmask")) == NULL)
goto no_props;
channelmask = pw_properties_parse_uint64(str);
if ((str = pw_properties_get(properties, "audio-dsp.rate")) == NULL)
goto no_props;
@ -119,7 +125,7 @@ static void *create_object(void *_data,
dsp = pw_audio_dsp_new(pw_module_get_core(d->module),
properties,
direction,
channels, rate, maxbuffer,
channels, channelmask, rate, maxbuffer,
sizeof(struct node_data));
if (dsp == NULL)