George Kiagiadakis
0002722289
simple-policy: compare client creation times so that the "last one wins"
...
When two clients have the same role, the current policy should
favor the newest client.
2019-07-30 14:05:40 +03:00
George Kiagiadakis
b05ae5f09c
simple-policy: do not leak client endpoints when rescanning
2019-07-30 13:17:58 +03:00
Julian Bouzas
efbefe9e0e
simple-policy: fix bug when finding endpoints
2019-07-25 12:24:48 +03:00
George Kiagiadakis
eaaa9f7f35
simple-policy: remove the idle callback when the object finalizes
...
Avoids crashing if a rescan is scheduled but the policy module is
destroyed in the meantime
2019-07-12 19:43:07 +03:00
George Kiagiadakis
1ed004c3c1
policy: implement a basic policy based on role priorities
...
* Every client has a priority based on its role
* For playback, we allow only a single client to play at a time
* For capture, we allow all clients to capture simultaneously
* Every time the "selected" device changes (either because devices
are discovered/removed or because the user changed the selection),
the clients are re-linked to the new "selected" device.
* When a playback client quits and there are others waiting unlinked,
the highest priority one is linked automatically.
* This also properly fixes re-linking the correct client(s) to the
correct device(s) when wireplumber exits and restarts.
2019-07-12 19:28:27 +03:00
Julian Bouzas
536df13709
simple-policy: delay unhandled enpoints if target is not found
2019-07-12 09:44:32 -04:00
George Kiagiadakis
a2bf7e3999
policy: take into account the role of the client when linking it
...
This allows linking the client to the stream that has the same name
as the role that it requests.
2019-07-12 14:40:19 +03:00
Julian Bouzas
51facef4e4
simple-policy: unlink the target endpoint if it is already linked
2019-07-10 11:18:09 -04:00
George Kiagiadakis
700f55670a
simple-policy: match the requested role to a stream in find_endpoint
...
... and simplify some code there
2019-07-09 13:20:39 -04:00
Julian Bouzas
ab55116653
simple-policy: handle both input and output clients
2019-06-28 13:04:28 -04:00
Julian Bouzas
5429d57cb1
endpoint-link: make contruction async
2019-06-28 12:33:00 -04:00
George Kiagiadakis
7c7c65de5a
simple-policy: allow configuring the default audio devices via module arguments
2019-06-28 13:32:07 +03:00
George Kiagiadakis
33391f4246
simple-policy: select by default the first non-loopback device
...
This is a bit of a hack, temporarily needed for AGL.
2019-06-26 13:33:50 +03:00
George Kiagiadakis
2da44762df
m-simple-policy: find_endpoint: ref the endpoint only if it's not NULL
2019-06-20 13:00:16 +03:00
George Kiagiadakis
aa5b16f8df
module-mixer: implement the "Mixer/Audio" endpoint provider
...
This provides high level volume controls for the AGL audiomixer
binding and the applications using it.
2019-06-18 19:58:42 +03:00
George Kiagiadakis
dcbe3a6f10
modules: move the "selected" endpoint logic to the simple-policy module and improve it
...
We now have always a "selected" endpoint for each direction (source, sink)
that is picked as the first available endpoint at startup,
and it changes automatically if the currently selected endpoint is removed
2019-06-18 19:44:28 +03:00
George Kiagiadakis
ecad76d995
policy: consume floating reference of GVariant in _find_endpoint()
2019-06-18 17:41:34 +03:00
George Kiagiadakis
a93b47690e
modules: re-implement the simple policy module using WpPolicy
2019-06-13 14:57:59 +03:00