mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
jack: use node.passive to make passive links
Let the node.passive property make passive links. PIPEWIRE_LINK_PASSIVE overrides the node property. Add some nice tweaks for qsynth so that it suspends and fades out nicely by default.
This commit is contained in:
parent
ead59e750f
commit
8e9b136b10
2 changed files with 16 additions and 7 deletions
|
|
@ -3389,6 +3389,8 @@ jack_client_t * jack_client_open (const char *client_name,
|
|||
pw_properties_set(client->props, PW_KEY_NODE_LATENCY, str);
|
||||
if ((str = getenv("PIPEWIRE_RATE")) != NULL)
|
||||
pw_properties_set(client->props, PW_KEY_NODE_RATE, str);
|
||||
if ((str = getenv("PIPEWIRE_LINK_PASSIVE")) != NULL)
|
||||
pw_properties_set(client->props, PW_KEY_NODE_PASSIVE, str);
|
||||
|
||||
if ((str = pw_properties_get(client->props, PW_KEY_NODE_LATENCY)) != NULL) {
|
||||
uint32_t num, denom;
|
||||
|
|
@ -5172,7 +5174,7 @@ int jack_connect (jack_client_t *client,
|
|||
items[props.n_items++] = SPA_DICT_ITEM_INIT(PW_KEY_LINK_INPUT_NODE, val[2]);
|
||||
items[props.n_items++] = SPA_DICT_ITEM_INIT(PW_KEY_LINK_INPUT_PORT, val[3]);
|
||||
items[props.n_items++] = SPA_DICT_ITEM_INIT(PW_KEY_OBJECT_LINGER, "true");
|
||||
if ((str = getenv("PIPEWIRE_LINK_PASSIVE")) != NULL &&
|
||||
if ((str = pw_properties_get(c->props, PW_KEY_NODE_PASSIVE)) != NULL &&
|
||||
pw_properties_parse_bool(str))
|
||||
items[props.n_items++] = SPA_DICT_ITEM_INIT(PW_KEY_LINK_PASSIVE, "true");
|
||||
|
||||
|
|
|
|||
|
|
@ -104,15 +104,22 @@ jack.rules = [
|
|||
}
|
||||
}
|
||||
}
|
||||
{
|
||||
matches = [
|
||||
{
|
||||
application.process.binary = "jack_bufsize"
|
||||
}
|
||||
{ matches = [
|
||||
{ application.process.binary = "jack_bufsize" }
|
||||
]
|
||||
actions = {
|
||||
update-props = {
|
||||
jack.global-buffer-size = true
|
||||
jack.global-buffer-size = true # quantum set globally using metadata
|
||||
}
|
||||
}
|
||||
}
|
||||
{ matches = [
|
||||
{ application.process.binary = "qsynth" }
|
||||
]
|
||||
actions = {
|
||||
update-props = {
|
||||
node.pause-on-idle = false # makes audio fade out when idle
|
||||
node.passive = true # makes the sink and qsynth suspend
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue