mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-05 13:30:02 -05:00
pulse-server: set monitor.channel-volumes=true by default
Make a null-sink with monitor.channel-volumes=true by default if not defined otherwise. This ensures the volume of the null-sink is always transfered to the monitor ports. Also only set the object.linger flag when undefined.
This commit is contained in:
parent
1201795c46
commit
648c9b432c
1 changed files with 7 additions and 2 deletions
|
|
@ -170,7 +170,7 @@ struct module *create_module_null_sink(struct impl *impl, const char *argument)
|
||||||
pw_properties_set(props, SPA_KEY_AUDIO_POSITION, s);
|
pw_properties_set(props, SPA_KEY_AUDIO_POSITION, s);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((str = pw_properties_get(props, PW_KEY_MEDIA_CLASS)) == NULL)
|
if (pw_properties_get(props, PW_KEY_MEDIA_CLASS) == NULL)
|
||||||
pw_properties_set(props, PW_KEY_MEDIA_CLASS, "Audio/Sink");
|
pw_properties_set(props, PW_KEY_MEDIA_CLASS, "Audio/Sink");
|
||||||
|
|
||||||
if ((str = pw_properties_get(props, "device.description")) != NULL) {
|
if ((str = pw_properties_get(props, "device.description")) != NULL) {
|
||||||
|
|
@ -187,8 +187,13 @@ struct module *create_module_null_sink(struct impl *impl, const char *argument)
|
||||||
class ? class : "", (class && class[0] != '\0') ? " " : "");
|
class ? class : "", (class && class[0] != '\0') ? " " : "");
|
||||||
}
|
}
|
||||||
pw_properties_set(props, PW_KEY_FACTORY_NAME, "support.null-audio-sink");
|
pw_properties_set(props, PW_KEY_FACTORY_NAME, "support.null-audio-sink");
|
||||||
|
|
||||||
|
if (pw_properties_get(props, PW_KEY_OBJECT_LINGER) == NULL)
|
||||||
pw_properties_set(props, PW_KEY_OBJECT_LINGER, "true");
|
pw_properties_set(props, PW_KEY_OBJECT_LINGER, "true");
|
||||||
|
|
||||||
|
if (pw_properties_get(props, "monitor.channel-volumes") == NULL)
|
||||||
|
pw_properties_set(props, "monitor.channel-volumes", "true");
|
||||||
|
|
||||||
module = module_new(impl, &module_null_sink_methods, sizeof(*d));
|
module = module_new(impl, &module_null_sink_methods, sizeof(*d));
|
||||||
if (module == NULL) {
|
if (module == NULL) {
|
||||||
res = -errno;
|
res = -errno;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue