+ use the pw_proxy API to find the bound id instead
of relying on WpGlobal
This has the advantage that it works also for exported
objects and for objects that have been created by calling
into a remote factory (such as the link-factory), so we can
now know the global id of all proxies, not only the ones
that have been created by the registry.
The alsa.pcm devices currently use "device.api" = "alsa:pcm"
but then the node overrides this later to just "alsa", which
is confusing. For now, let's match "alsa:pcm" in the monitor,
even though this does not appear on the node later.
This commit fixes device preferences in wireplumber.conf,
which were broken because the alsa endpoint names were empty
of info about the alsa device
This allows the bluealsa gstreamer helper to link to the speakers
constantly, with both A2DP and HFP streams. If this is not enabled,
only one of those will manage to connect, randomly.
This is definitely something to be superseeded by proper policy
management implemented with configuration files
Running audioconvert in merge+split mode is the only way to make this work with
the adapter, since the adapter does not support passing multiple channels on
a single port right now, and if it does at some point, it will be without a
mixing node on the port, which means we will not be able to mix multiple
audioconvert nodes on the same adapter. In the future we need to consider
writing a lighter volume node with multiple channels support to replace
audioconvert.
The new linking algorithm now takes into account the channel positions and makes
sure to link the correct channels together. Also, it avoids passing the port
proxies inside the GVariants, thus making the algorithm a bit more generic
and easier to unit test.