mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
impl-port: copy node.terminal and node.physical properties
Make 2 new node properties to make all ports of a node terminal or physical. Skip the monitor ports for this, though, they can never be terminal or physical. This is important for JACK clients that often enumerate physical terminal ports in order to link to them and with this you can make JACK clients link to virtual sinks and sources as well.
This commit is contained in:
parent
00d983a40d
commit
12464ed1bb
2 changed files with 10 additions and 0 deletions
|
|
@ -1238,6 +1238,13 @@ int pw_impl_port_add(struct pw_impl_port *port, struct pw_impl_node *node)
|
|||
|
||||
is_monitor = pw_properties_get_bool(port->properties, PW_KEY_PORT_MONITOR, false);
|
||||
|
||||
if (!is_monitor) {
|
||||
if ((str = pw_properties_get(nprops, PW_KEY_NODE_TERMINAL)) != NULL)
|
||||
pw_properties_set(port->properties, PW_KEY_PORT_TERMINAL, str);
|
||||
if ((str = pw_properties_get(nprops, PW_KEY_NODE_PHYSICAL)) != NULL)
|
||||
pw_properties_set(port->properties, PW_KEY_PORT_PHYSICAL, str);
|
||||
}
|
||||
|
||||
port->ignore_latency = pw_properties_get_bool(port->properties, PW_KEY_PORT_IGNORE_LATENCY, false);
|
||||
port->exclusive = pw_properties_get_bool(port->properties, PW_KEY_PORT_EXCLUSIVE, node->exclusive);
|
||||
|
||||
|
|
|
|||
|
|
@ -229,6 +229,9 @@ extern "C" {
|
|||
* playback or disable the prefix
|
||||
* completely if an empty string
|
||||
* is provided */
|
||||
#define PW_KEY_NODE_PHYSICAL "node.physical" /**< ports from the node are physical */
|
||||
#define PW_KEY_NODE_TERMINAL "node.terminal" /**< ports from the node are terminal */
|
||||
|
||||
/** Port keys */
|
||||
#define PW_KEY_PORT_ID "port.id" /**< port id */
|
||||
#define PW_KEY_PORT_NAME "port.name" /**< port name */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue