mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
node: remove info from node interface
Replace with info event emited when callbacks are set. This makes it easier to implement dynamic changes.
This commit is contained in:
parent
57e94f7bc4
commit
7bc9c1ebfe
23 changed files with 69 additions and 89 deletions
|
|
@ -135,6 +135,18 @@ inspect_port_params(struct data *data, struct spa_node *node,
|
|||
}
|
||||
}
|
||||
|
||||
static void node_info(void *data, const struct spa_dict *info)
|
||||
{
|
||||
printf("node properties:\n");
|
||||
spa_debug_dict(2, info);
|
||||
}
|
||||
|
||||
static const struct spa_node_callbacks node_callbacks =
|
||||
{
|
||||
SPA_VERSION_NODE_CALLBACKS,
|
||||
.info = node_info,
|
||||
};
|
||||
|
||||
static void inspect_node(struct data *data, struct spa_node *node)
|
||||
{
|
||||
int res;
|
||||
|
|
@ -142,10 +154,7 @@ static void inspect_node(struct data *data, struct spa_node *node)
|
|||
uint32_t *in_ports, *out_ports;
|
||||
|
||||
printf("node info:\n");
|
||||
if (node->info)
|
||||
spa_debug_dict(2, node->info);
|
||||
else
|
||||
printf(" none\n");
|
||||
spa_node_set_callbacks(node, &node_callbacks, data);
|
||||
|
||||
inspect_node_params(data, node);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue