mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-10 13:30:05 -05:00
node: make add_listener method
Make struct spa_node_events for events emited from the main thread and keep the spa_node_callbacks for the data thread callbacks. The add_listener method installs the events and it's possible to install multiple handles. Adding a listener first emits the info and port_info events when installed, similar to how the PipeWire proxy bind works. This removes the need for the spa_pending_queue and makes it easier to implement the _sync versions. Add some helpers to make it easier for plugins to emit all the info to new listeners. Use the listeners for devices as well.
This commit is contained in:
parent
61ce4e77f6
commit
0390969228
53 changed files with 1774 additions and 1307 deletions
|
|
@ -39,8 +39,8 @@ extern "C" {
|
|||
int spa_debug_port_info(int indent, const struct spa_port_info *info)
|
||||
{
|
||||
spa_debug("%*s" "struct spa_port_info %p:", indent, "", info);
|
||||
spa_debug("%*s" " flags: \t%08x", indent, "", info->flags);
|
||||
spa_debug("%*s" " rate: \t%u", indent, "", info->rate);
|
||||
spa_debug("%*s" " flags: \t%08lx", indent, "", info->flags);
|
||||
spa_debug("%*s" " rate: \t%d/%d", indent, "", info->rate.num, info->rate.denom);
|
||||
spa_debug("%*s" " props:", indent, "");
|
||||
if (info->props)
|
||||
spa_debug_dict(indent + 2, info->props);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue