George Kiagiadakis
ee00a24688
core: destroy globals in _dispose() so that the global-removed signal is dispatched
...
signal emission apparently does not work in _finalize()
Fixes some critical warnings from remote-endpoint.c because disconnection
from the destroyed endpoints did not happen
2019-06-20 13:00:16 +03:00
George Kiagiadakis
643d3d61bc
Merge branch 'proxy-global-id' into 'master'
...
Proxy global id
See merge request gkiagia/wireplumber!11
2019-06-19 13:52:26 +00:00
Julian Bouzas
601749d721
audio-softdsp-endpoint: set module instead of core in the module data
2019-06-19 09:13:02 -04:00
Julian Bouzas
fc7ebc2c31
proxy: add global_id property
2019-06-19 09:07:00 -04:00
George Kiagiadakis
0ad9464b54
softdsp-endpoint: workaround pipewire bug
...
spa audioconvert (the backend of audio-dsp) does not adevertise
property changes, therefore subscribe_params() is useless.
In order to get the real value from the node we need to call
enum_params() manually.
https://github.com/PipeWire/pipewire/issues/157
2019-06-19 12:19:36 +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
5d93cf338b
remote-endpoint: disconnect the control-value change callback when the proxy is destroyed
...
This avoids the theoretical crash that would happen if you change
the control value on an endpoint whose client-endpoint proxy has
already been destroyed
2019-06-18 19:42:19 +03:00
George Kiagiadakis
b770cf6a3e
core: remove_global: remove object from the list before triggering the notification
...
This avoids being able to find the same object on the globals list
from code that is connected to the signal.
2019-06-18 19:39:52 +03:00
George Kiagiadakis
ca1453febd
endpoint: add some useful API for querying info about streams & controls
2019-06-18 17:42:06 +03:00
George Kiagiadakis
ecad76d995
policy: consume floating reference of GVariant in _find_endpoint()
2019-06-18 17:41:34 +03:00
George Kiagiadakis
52273e99a0
Merge branch 'unregister-endpoint' into 'master'
...
Unregister endpoint
See merge request gkiagia/wireplumber!10
2019-06-18 14:25:35 +00:00
Julian Bouzas
a471a2df13
proxy: remove unneeded core reference
2019-06-18 10:18:21 -04:00
Julian Bouzas
42bdf3ee6d
modules: unregister the endpoints when their proxy is destroyed
2019-06-18 10:10:20 -04:00
Julian Bouzas
922065f97d
proxy: add destroyed signal
2019-06-18 10:09:40 -04:00
George Kiagiadakis
994e7d19d8
Merge branch 'refcount-fix' into 'master'
...
modules: fix proxy ref-count
See merge request gkiagia/wireplumber!9
2019-06-18 12:36:49 +00:00
Julian Bouzas
3feddf5579
modules: fix proxy ref-count
2019-06-18 08:34:54 -04:00
George Kiagiadakis
e603ed4215
lib: add some debug statements to debug the destruction sequence
2019-06-18 10:33:38 +03:00
George Kiagiadakis
64affcaf49
proxy: maintain a weak ref to the core
...
avoids criticals and crashes when the core is destroyed earlier
2019-06-18 10:21:58 +03:00
George Kiagiadakis
0b3433d732
modules: fix some ref counting and memory {de-,}allocation issues
2019-06-18 10:02:01 +03:00
George Kiagiadakis
ab73fd6eb0
endpoint: maintain a weak ref to the core since construction time
...
+ add a method to retrieve the core
+ change the register function to not require the core as a parameter
2019-06-18 09:23:40 +03:00
George Kiagiadakis
f5279fcb66
Merge branch 'use-proxy-api' into 'master'
...
Use proxy api in module-pipewire and simple-endpoint
See merge request gkiagia/wireplumber!8
2019-06-18 05:20:18 +00:00
Julian Bouzas
1f2386c08d
module-pipewire and simple-endpoint: use the new Proxy API
2019-06-17 14:37:14 -04:00
Julian Bouzas
8877e0438d
alsa-udev: fix minor bug
2019-06-17 14:26:24 -04:00
Julian Bouzas
7337f9c19f
audio-softdsp-endpoint: fix proxy port property description
2019-06-17 14:26:24 -04:00
George Kiagiadakis
7b9e8a030e
lib: add a new WpRemote base class and move the pw_remote glue into a new WpRemotePipewire
...
This is a cleaner way to interface with the remote pipewire daemon.
The WpRemote base class can be subclassed also for interfacing
with other daemons (hardware-specific managers, etc)
2019-06-17 20:28:06 +03:00
George Kiagiadakis
08ef641a04
Merge branch 'proxy-api' into 'master'
...
Proxy API
See merge request gkiagia/wireplumber!7
2019-06-17 14:46:19 +00:00
Julian Bouzas
2c76103c30
modules: use the new proxy API
2019-06-17 10:42:59 -04:00
Julian Bouzas
aa1ce5cdd4
proxy: add API
2019-06-17 10:42:29 -04:00
George Kiagiadakis
5a863fe50c
WpPolicy: add a way of signaling policy changes
...
This can be used by code that depends on policy to re-evaluate
choices they have made in the past that could now change based
on the new policy.
2019-06-14 15:29:57 +03:00
George Kiagiadakis
5cb1232f27
m-pipewire: temporarily add the sync_core_with_cb hack
...
We need to delay the registration of the simple endpoint because
it needs to get some information from the "info" callback of pipewire
before we can use it in a link.
2019-06-13 16:52:16 +03:00
George Kiagiadakis
a93b47690e
modules: re-implement the simple policy module using WpPolicy
2019-06-13 14:57:59 +03:00
George Kiagiadakis
25d70c5446
lib: add new WpPolicy class and basic policy management functionality
2019-06-13 14:51:20 +03:00
George Kiagiadakis
18f3e764c0
simple-policy: link client to the "selected" endpoint
2019-06-11 14:07:54 +03:00
George Kiagiadakis
b83bcd091e
softdsp-endpoint: automatically deselect other endpoints when one is selected
...
Only one endpoint of a certain media class can be selected at a time
2019-06-11 13:29:20 +03:00
George Kiagiadakis
8f544329b9
remote-endpoint: do not require a stream id on controls
...
the stream id is optional, a control may apply globally to all streams
2019-06-11 13:28:33 +03:00
George Kiagiadakis
45dc9786f4
endpoint: ref the endpoint while unregistering
...
The core may be the last object holding a reference to the endpoint,
so the unregister call may destroy it.
2019-06-11 12:49:11 +03:00
George Kiagiadakis
eabd2a49a4
softdsp-endpoint: add the "selected" control
...
This shall be a temporary method of selecting which endpoint
is going to be the default input or output, for testing purposes
2019-06-11 11:58:12 +03:00
George Kiagiadakis
c2f0d65723
softdsp-endpoint: add master volume & mute controls
2019-06-11 11:38:56 +03:00
George Kiagiadakis
e43d2d523d
softdsp-endpoint: destroy the DSP->node link when the DSP becomes idle
2019-06-11 11:18:53 +03:00
George Kiagiadakis
3c201b610f
softdsp-endpoint: copy format using standard struct assignment
2019-06-11 11:05:40 +03:00
George Kiagiadakis
acc3eef294
softdsp-endpoint: improve destruction sequence
...
- Set the node proxy to NULL when it is destroyed externally
so that we don't try to destroy it a second time in finalize.
- Don't remove the dsp_listener, as this is already done inside
the node proxy destroy sequence (but keep removing the node
listener to avoid calling node_proxy_destroy() from inside
finalize())
2019-06-11 10:57:56 +03:00
George Kiagiadakis
c9f03b2cad
softdsp-endpoint: restructure some code, fix some coding style issues
2019-06-11 10:51:34 +03:00
George Kiagiadakis
80831c9320
Cleanup trailing whitespaces
2019-06-11 10:11:24 +03:00
George Kiagiadakis
aa0cfbeb76
Merge branch 'endpoint-linking' into 'master'
...
Endpoint linking
See merge request gkiagia/wireplumber!5
2019-06-10 16:38:00 +00:00
Julian Bouzas
b87e9775ce
simple-policy: add new module
2019-06-10 11:52:03 -04:00
Julian Bouzas
f1d1bff593
modules: add softdsp-endpoit and endpoint linking implementations
2019-06-10 11:51:18 -04:00
Julian Bouzas
cad748ae91
endpoint: set core to null after unregistering endpoint and not before
2019-06-06 12:51:05 -04:00
George Kiagiadakis
1962a8ca1c
daemon: quit when the pipewire remote disconnects or signals an error
...
This is implemented in a slightly hacky way, we register the GMainLoop
as a global object and use it from the module to quit the daemon.
This is bad design because the module assumes it is loaded inside
our daemon.
In the future, this should change. It looks like we should have an
object that tracks the state of PipeWire and main() should track
state changes of that object and decide what to do.
2019-06-05 18:38:56 +03:00
George Kiagiadakis
d4ddad18b3
m-pipewire/simple-endpoint: implement volume & mute controls
2019-06-05 17:20:57 +03:00