Commit graph

35 commits

Author SHA1 Message Date
Wim Taymans
72d8778e3f si-adapter: handle dont-remix streams
Don't-remix streams don't change their channel mapping based on
the device they connect to but are always configured with their
default channel mapping, just like devices.

This fixes the gnome-control-center channel test.

This patch also removes the 1 channel -> many patch because it is
not the right thing to do in this case and should be implemented
with some proper channel mapping patch later.
2021-06-07 09:56:54 +02:00
George Kiagiadakis
bf9d4c4ed7 m-si-standard-link: fix number of links check
self->node_links is a GPtrArray*
2021-05-27 17:01:00 +03:00
Julian Bouzas
bd90783398 m-si-standard-link: remove unused manage.lifetime configuration property 2021-05-24 11:07:59 -04:00
George Kiagiadakis
ac9e1e89c4 wp: remove WpSession and WpEndpointLink
We have ended up not using them, so let's not carry them
in the ABI of 0.4

We can always revert that, but let's first decide how
these objects should be used
2021-05-21 19:57:31 +03:00
Julian Bouzas
e1faf3f095 si-standard-link: configure the format in WpSiAdapters before linking 2021-05-12 10:37:18 -04:00
Julian Bouzas
47ae4f28a3 si-standard-link: make sure create_links creates at least 1 link 2021-05-11 10:56:50 -04:00
Julian Bouzas
d68636f9b3 si-interfaces: rename WpSiPortInfo to WpSiLinkable 2021-05-11 10:56:44 -04:00
Julian Bouzas
2caac5fa87 si-standard-link: call parent class finalize once finalized 2021-04-07 13:21:40 -04:00
Julian Bouzas
552b04ed7d m-si-standard-link: properly set in item port context when configuring 2021-04-06 14:04:34 -04:00
Julian Bouzas
fb1daa0bf2 modules: use dots instead of dashes for session item properties
Keeps consistency with PipeWire
2021-04-02 11:22:22 -04:00
Julian Bouzas
75d53dbef3 m-si-standard-link: make sure in/out items are valid before activating 2021-03-31 10:51:20 -04:00
Julian Bouzas
0d71565d63 m-si-standard-link: set out-item-id and in-item-id properties 2021-03-26 16:16:02 -04:00
Julian Bouzas
ebf52adb21 si-interfaces: make WpSiLink work with WpSiPortInfo instead of WpSiEndpoint 2021-03-26 16:16:02 -04:00
Julian Bouzas
64cf2bd644 si-interfaces: rename WpSiEndpointAcquisition to WpSiAcquisition
The get_endpoint_acquisition() vmethod has also been moved to WpSiPortInfo, and
therefore renamed to get_acquisition().
2021-03-26 16:16:02 -04:00
Julian Bouzas
13fc0adb22 m-si-standard-link: use a weak reference for in and out endpoints
Allows checking if the endpoints are still valid before releasing the
acquisition. Sometimes the endpoints are destroyed before the link, and
releasing acquisition is not needed. There is no way to check that with raw
pointers.
2021-03-26 16:15:38 -04:00
Julian Bouzas
0bef8280d7 m-si-standard-link: fix in-endpoint check when configuring 2021-03-26 15:56:07 -04:00
Julian Bouzas
120aab04ae session-item: refactor and inherit from WpObject
This adds WP_SESSION_ITEM_FEATURE_ACTIVE and WP_SESSION_ITEM_FEATURE_EXPORTED
features, so _activate and _export APIs have been removed. Modules and unit
tests have also been updated.
2021-03-18 14:30:05 -04:00
Julian Bouzas
12b2c00d0b lib: remove WpEndpointStream API
Add all that goes with it.
2021-03-18 12:10:37 -04:00
George Kiagiadakis
0d072874a1 lib: introduce WpComponentLoader and remove WpModule
The component loader is a more generic and extensible mechanism
of loading components; modules are one type of component...
The idea is to make scripts and config files also be components,
loaded by plugins that inherit WpComponentLoader
2021-02-03 17:16:51 +02:00
George Kiagiadakis
ccdc354445 modules: port modules and their tests to the new proxy APIs
Disable m-session-settings for now, as it needs further work
2020-11-15 20:26:15 +02:00
George Kiagiadakis
aabf6beda7 si-convert: use passive links
Requires PipeWire < 0.3.3 or > 0.3.6 to actually work
2020-06-17 14:44:29 +03:00
George Kiagiadakis
244fa28d17 si-standard-link: allow linking MONO capture clients
In case we have a multi-channel capture device and a mono client,
treat the MONO port as UNKNOWN and let it link with the first
port available on the device

Easy to test with arecord, which by default captures in MONO
2020-06-17 12:55:12 +03:00
George Kiagiadakis
e944abbcd5 si-standard-link: associate links with endpoint-links 2020-06-02 13:09:00 +03:00
Julian Bouzas
6a73179d57 si-standard-link: fix memleak when creating links 2020-05-19 10:18:51 -04:00
Julian Bouzas
e481c998a4 si-standard-link: check if stream parent is valid before acquisition 2020-05-15 08:21:49 -04:00
Julian Bouzas
7e8e6da857 si-standard-link: get the core from the stream node when its endpoint link proxy is not valid 2020-05-12 09:47:27 -04:00
George Kiagiadakis
c02bff50cd si-standard-link: add options to use different port contexts 2020-05-07 16:48:06 +03:00
George Kiagiadakis
cc72b3757c si-standard-link: manage lifetime internally 2020-05-07 16:38:14 +03:00
George Kiagiadakis
7966a8d456 si-standard-link: fix endpoint linking bugs and add some debug statements 2020-05-05 18:04:05 +03:00
Julian Bouzas
791e9170aa si-interfaces: transfer full when returning from _get_stream_parent_endpoint 2020-05-03 19:54:31 +03:00
George Kiagiadakis
d61b7904f9 modules: fix small issues in the session items 2020-04-23 15:22:32 +03:00
George Kiagiadakis
49b63b6045 session-item: refactor export to use a process similar to activate
+ expose the export transition in the session item class
+ make the export-related flags immutable
+ add an export error flag
+ update and improve documentation
2020-04-16 17:38:31 +03:00
George Kiagiadakis
441a778b2e session-item: introduce a rollback() virtual method
+ replace calling execute_step(..., STEP_ERROR) with rollback
+ implement deactivate internally using rollback

This unifies deactivation steps, which are common between deactivate()
and calling execute_step() with WP_TRANSITION_STEP_ERROR at the
end of a failed activation transition.
2020-04-16 13:18:21 +03:00
George Kiagiadakis
6b51e5842c tests: add session-item unit test 2020-04-16 11:55:23 +03:00
George Kiagiadakis
0e855d854a modules: implement si-standard-link, the default WpSiLink implementation 2020-04-11 11:05:09 +03:00