pulse-server: add more properties

Add device.class property
This commit is contained in:
Wim Taymans 2022-01-29 11:21:31 +01:00
parent 78ff44b91d
commit 115875dc5b
4 changed files with 12 additions and 2 deletions

View file

@ -212,6 +212,8 @@ struct module *create_module_ladspa_sink(struct impl *impl, const char *argument
}
if (pw_properties_get(capture_props, PW_KEY_MEDIA_CLASS) == NULL)
pw_properties_set(capture_props, PW_KEY_MEDIA_CLASS, "Audio/Sink");
if (pw_properties_get(capture_props, PW_KEY_DEVICE_CLASS) == NULL)
pw_properties_set(capture_props, PW_KEY_DEVICE_CLASS, "filter");
if ((str = pw_properties_get(props, "master")) != NULL ||
(str = pw_properties_get(props, "sink_master")) != NULL) {

View file

@ -212,6 +212,8 @@ struct module *create_module_ladspa_source(struct impl *impl, const char *argume
}
if (pw_properties_get(playback_props, PW_KEY_MEDIA_CLASS) == NULL)
pw_properties_set(playback_props, PW_KEY_MEDIA_CLASS, "Audio/Source");
if (pw_properties_get(playback_props, PW_KEY_DEVICE_CLASS) == NULL)
pw_properties_set(playback_props, PW_KEY_DEVICE_CLASS, "filter");
if ((str = pw_properties_get(props, "master")) != NULL ||
(str = pw_properties_get(props, "source_master")) != NULL) {

View file

@ -176,7 +176,10 @@ struct module *create_module_remap_sink(struct impl *impl, const char *argument)
module_args_add_props(capture_props, str);
pw_properties_set(props, "sink_properties", NULL);
}
pw_properties_set(capture_props, PW_KEY_MEDIA_CLASS, "Audio/Sink");
if (pw_properties_get(capture_props, PW_KEY_MEDIA_CLASS) == NULL)
pw_properties_set(capture_props, PW_KEY_MEDIA_CLASS, "Audio/Sink");
if (pw_properties_get(capture_props, PW_KEY_DEVICE_CLASS) == NULL)
pw_properties_set(capture_props, PW_KEY_DEVICE_CLASS, "filter");
if (pw_properties_get(capture_props, PW_KEY_NODE_DESCRIPTION) == NULL) {
str = pw_properties_get(props, "master");

View file

@ -176,7 +176,10 @@ struct module *create_module_remap_source(struct impl *impl, const char *argumen
module_args_add_props(playback_props, str);
pw_properties_set(props, "source_properties", NULL);
}
pw_properties_set(playback_props, PW_KEY_MEDIA_CLASS, "Audio/Source");
if (pw_properties_get(playback_props, PW_KEY_MEDIA_CLASS) == NULL)
pw_properties_set(playback_props, PW_KEY_MEDIA_CLASS, "Audio/Source");
if (pw_properties_get(playback_props, PW_KEY_DEVICE_CLASS) == NULL)
pw_properties_set(playback_props, PW_KEY_DEVICE_CLASS, "filter");
if (pw_properties_get(playback_props, PW_KEY_NODE_DESCRIPTION) == NULL) {
str = pw_properties_get(props, "master");