Skip to content
Snippets Groups Projects
Commit e944abbc authored by George Kiagiadakis's avatar George Kiagiadakis
Browse files

si-standard-link: associate links with endpoint-links

parent 128b67e2
No related branches found
No related tags found
No related merge requests found
...@@ -256,6 +256,7 @@ create_links (WpSiStandardLink * self, WpTransition * transition, ...@@ -256,6 +256,7 @@ create_links (WpSiStandardLink * self, WpTransition * transition,
guint32 out_channel, in_channel; guint32 out_channel, in_channel;
gboolean link_all = FALSE; gboolean link_all = FALSE;
guint i; guint i;
guint32 eplink_id;
/* tuple format: /* tuple format:
uint32 node_id; uint32 node_id;
...@@ -270,6 +271,9 @@ create_links (WpSiStandardLink * self, WpTransition * transition, ...@@ -270,6 +271,9 @@ create_links (WpSiStandardLink * self, WpTransition * transition,
core = find_core (self); core = find_core (self);
g_return_val_if_fail (core, FALSE); g_return_val_if_fail (core, FALSE);
eplink_id = wp_session_item_get_associated_proxy_id (WP_SESSION_ITEM (self),
WP_TYPE_ENDPOINT_LINK);
self->n_async_ops_wait = 0; self->n_async_ops_wait = 0;
self->node_links = g_ptr_array_new_with_free_func (g_object_unref); self->node_links = g_ptr_array_new_with_free_func (g_object_unref);
...@@ -316,6 +320,8 @@ create_links (WpSiStandardLink * self, WpTransition * transition, ...@@ -316,6 +320,8 @@ create_links (WpSiStandardLink * self, WpTransition * transition,
wp_properties_setf (props, PW_KEY_LINK_OUTPUT_PORT, "%u", out_port_id); wp_properties_setf (props, PW_KEY_LINK_OUTPUT_PORT, "%u", out_port_id);
wp_properties_setf (props, PW_KEY_LINK_INPUT_NODE, "%u", in_node_id); wp_properties_setf (props, PW_KEY_LINK_INPUT_NODE, "%u", in_node_id);
wp_properties_setf (props, PW_KEY_LINK_INPUT_PORT, "%u", in_port_id); wp_properties_setf (props, PW_KEY_LINK_INPUT_PORT, "%u", in_port_id);
if (eplink_id != SPA_ID_INVALID)
wp_properties_setf (props, "endpoint-link.id", "%u", eplink_id);
wp_debug_object (self, "create pw link: %u:%u (%s) -> %u:%u (%s)", wp_debug_object (self, "create pw link: %u:%u (%s) -> %u:%u (%s)",
out_node_id, out_port_id, out_node_id, out_port_id,
......
...@@ -286,6 +286,7 @@ struct { ...@@ -286,6 +286,7 @@ struct {
{ PW_KEY_CLIENT_ID, "Client" }, { PW_KEY_CLIENT_ID, "Client" },
{ PW_KEY_DEVICE_ID, "Device" }, { PW_KEY_DEVICE_ID, "Device" },
{ PW_KEY_ENDPOINT_CLIENT_ID, NULL }, { PW_KEY_ENDPOINT_CLIENT_ID, NULL },
{ "endpoint-link.id", "EndpointLink" },
{ PW_KEY_ENDPOINT_STREAM_ID, "EndpointStream" }, { PW_KEY_ENDPOINT_STREAM_ID, "EndpointStream" },
{ PW_KEY_ENDPOINT_LINK_OUTPUT_ENDPOINT, NULL }, { PW_KEY_ENDPOINT_LINK_OUTPUT_ENDPOINT, NULL },
{ PW_KEY_ENDPOINT_LINK_OUTPUT_STREAM, NULL }, { PW_KEY_ENDPOINT_LINK_OUTPUT_STREAM, NULL },
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment