Commit graph

1799 commits

Author SHA1 Message Date
Julian Bouzas
0996f5a5ca spa-json: add wp_spa_json_to_string() API
Since the string length returned by wp_spa_pod_get_data() does not always match
the size of the actual json object because it is stored in contiguous memory, we
cannot always rely on that API to get the json string data.

The new wp_spa_pod_to_string() always allocates a new string with the same
length as the json size, guaranteeing that the string returned always represents
the json object, regardless of whether it is nested or not. It is always
recommented to use wp_spa_pod_to_string() unless you know what you are doing.
2022-06-27 10:07:16 +00:00
Julian Bouzas
a19c7f3d2f spa-json: only add the json data represented by its size
The data pointer of a WpSpaJson object can be bigger than the actual WpSpaJson
size. For example, this happens when iterating an array: instead of
re-allocating the nested data into a new region of memory, the iterator uses
the same region of memory as the parent, and just sets the pointer data and size
to the correct location when creating the nested WpSpaJson object.

This patch makes sure only the data represented by the size is added into the
builder when adding a json object, fixing issues that were happening before when
adding nested objects directly from a second WpSpaJson object.
2022-06-27 10:07:16 +00:00
Wim Taymans
8ade19ac59 config: rename empty.noise -> dither.noise 2022-06-27 11:50:33 +02:00
Anders Jonsson
2e39defd61 Update Swedish translation 2022-06-27 09:38:37 +00:00
Yuri Chornoivan
d462345c63 Update Ukrainian translation 2022-06-27 09:34:13 +00:00
Julian Bouzas
392bd81913 alsa.lua: remove node names from table when parent device is destroyed
Fixes #293
2022-06-27 08:52:36 +00:00
Julian Bouzas
76d87813a1 m-default-nodes: reevaluate nodes when ports changed
Currently, if the default node appears without ports for a short period of time,
the default nodes module will never select it immediately because it does not
listen for port changes. We want to listen for port changes to reevaluate again
the nodes that did not have ports before. This allows switching to the default
node as soon as it has ports if it did not had ports before.
2022-06-27 08:52:36 +00:00
Julian Bouzas
04198820f1 device: add new wp_spa_device_managed_object_new_iterator API 2022-06-27 08:52:36 +00:00
Julian Bouzas
c86410e708 iterator: skip NULL pointers when iterating pointer arrays 2022-06-27 08:52:36 +00:00
Wim Taymans
2536380a81 config: add more possible device properties 2022-06-24 14:11:26 +02:00
Piotr Drąg
23c0ea1254 Update Polish translation 2022-06-16 13:21:51 +02:00
Piotr Drąg
d50877b120 Update POTFILES.in 2022-06-15 05:55:26 +00:00
Julian Bouzas
3efb83ef08 dbus: fix bus type check when getting instance 2022-06-15 05:52:41 +00:00
Danial Behzadi
2e9549e168 po: add Persian language 2022-06-08 09:29:26 +00:00
Varnit Singh
f53efaabf1 wpctl: allow modifying volume levels using percentage/step amount. 2022-06-08 09:25:45 +00:00
Varnit Singh
e192deb7bc wpctl: Add get-volume command and functionality 2022-06-08 09:18:34 +00:00
Julian Bouzas
cee5ee7c37 core: add API to get virtual machine type 2022-06-02 12:34:16 -04:00
Julian Bouzas
46e7c5c144 m-reserve-device: use WpDbus API 2022-06-02 12:34:16 -04:00
Julian Bouzas
69b559399d modules: move all portal-permissionstore code into one file 2022-06-02 12:34:16 -04:00
Julian Bouzas
2c53486e0d m-portal-permissionstore: use WpDbus API 2022-06-02 12:34:16 -04:00
Julian Bouzas
9183787325 lib: add new WpDbus API 2022-06-02 12:34:16 -04:00
George Kiagiadakis
2ac384711d libcamera: give higher priority to external cameras
if you have plugged an external camera, that probably means you
prefer using that instead of the internal one
2022-05-31 12:15:11 +03:00
George Kiagiadakis
334a134471 v4l2: append "(V4L2)" in node descriptions
This is to make it easier to work with V4L2 and libcamera simultaneously
2022-05-31 10:53:01 +03:00
George Kiagiadakis
b44759ec3f libcamera: improve the front/back camera descriptions 2022-05-31 10:41:20 +03:00
George Kiagiadakis
6931050b7f v4l2/libcamera: set node.nick on nodes 2022-05-31 10:40:56 +03:00
George Kiagiadakis
2299c389b5 libcamera: set a user-friendly description for internal cameras 2022-05-30 11:06:46 +03:00
George Kiagiadakis
b345468e82 wpctl: print link states in the status output 2022-05-30 11:06:46 +03:00
George Kiagiadakis
2754b9899d link: add link state accessors and change signal 2022-05-30 11:06:46 +03:00
George Kiagiadakis
9ec2757d27 monitors: enable libcamera by default and set priority on all camera nodes
Currently v4l2 nodes will get higher priority than libcamera ones.
The default can be changed, of course, with wpctl.

Things are still not great if a camera is enumerated by both monitors.
The first node to be linked will grab the device and the second one
from the other subsystem will fail to negotiate.
2022-05-26 14:08:16 +03:00
Michael Olbrich
13b85bd4a2 m-lua-scripting: fix object refcounting
7908b8d7be2a2992c57cd549054eda7ce46e4b44 ("m-lua-scripting: allow
converting GValue holding NULL objects to Lua") accidentally added a second
refcount. As a result, the objects are never freeded.

Remove the second refcount to fix this.
2022-05-24 11:40:35 +02:00
Piotr Drąg
06e9285b25 Add po/POTFILES.skip
So false positives don’t show up on https://l10n.gnome.org/module/WirePlumber/
2022-05-22 12:34:44 +02:00
Julian Bouzas
392cce2136 m-default-nodes: don't check if all device nodes are ready when finding default node
This check was originally added to avoid a small audio glitch when changing
default nodes while also changing the device profile (eg Gnome Sound Settings).
The check is removed because it causes issues when disabling alsa nodes. There
are plans to fix the audio glitch issue in the future with the planned
event-dispatcher architecture.

Fixes #279
2022-05-20 13:39:47 +00:00
Julian Bouzas
c00c5a6675 alsa.lua: fix device name deduplication when reservation is enabled
Fixes #241
2022-05-19 07:43:12 -04:00
Julian Bouzas
c2f31bb550 m-lua-scripting: allow converting GValue holding NULL objects to Lua 2022-05-19 07:43:12 -04:00
George Kiagiadakis
1a534f17ed docs: fix WIREPLUMBER_DEBUG examples
See !259
2022-05-19 13:44:32 +03:00
George Kiagiadakis
459e3834da Enable proper syntax highlighting. 2022-05-16 11:01:41 +00:00
jasker5183
6e35daa0d2 Add alsa_monitor.rule example, capitalization, syntax. 2022-05-12 15:36:39 +00:00
George Kiagiadakis
1f04530920 config: fix enabled property to default to "true" when not defined
Fixes backwards compatibility with older config files

Fixes: #254
2022-05-12 12:19:38 +03:00
George Kiagiadakis
b4eba2999e examples: add a lua example showing how to load filter-chain from a script 2022-05-11 13:07:39 +03:00
George Kiagiadakis
3400acd0db release 0.4.10 2022-05-10 17:31:57 +03:00
George Kiagiadakis
dacc586898 properties: improve documentation of _get_count() 2022-05-10 15:27:31 +03:00
George Kiagiadakis
2eed279c9d i18n: remove the module and embed the gettext calls into the lua api
There is no need to have this as an optional module, since libintl
is a hard dependency of both PipeWire and GLib. This way we can keep
things a bit simpler and faster (no string copies and plugin lookups)

Bump meson dependency to 0.59 to benefit of the libintl lookup that
is now built into meson's dependency() function.
2022-05-10 15:16:09 +03:00
George Kiagiadakis
85d0ecfb40 si-interfaces: improve documentation on latest api additions 2022-05-10 15:16:09 +03:00
Sven Bartscher
8dc4c36dd4 Enable automatic bluetooth profile switching for Mumble
For some reason Mumble uses "game" as its media.role, but it is
actually a communication tool where a headset profile is apropriate.
2022-05-10 10:45:03 +02:00
Théo Lebrun
3bdacc414e config: add enabled property on monitors
Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
2022-05-05 08:22:08 +00:00
Julian Bouzas
7080e9961c policy-node: forward filter stream's format to filter device
Currently, when using filter nodes such as echo-cancel or filer-chain, the
ports format of the virtual stream node might not always match the format of its
associated virtual device node. This can happen if the virtual stream node is
linked with a real device node configured with many channels, such as surround
profile. In that case, the channel configuration is not forwarded to the virtual
device node, making the application not being aware of a surround setup.

This change listens for port format changes in the virtual stream nodes, and
reconfigures the virtual device node ports everytime the virtual stream node's
port format changes.

This behavior is experimental and optional, so it is disabled by default.
2022-05-05 08:09:21 +00:00
Julian Bouzas
07179452e2 m-lua-scripting: add WpSiAdapter APIs 2022-05-05 08:09:21 +00:00
Julian Bouzas
1675b37617 si-adapter: add ports state change signal 2022-05-05 08:09:21 +00:00
Julian Bouzas
5a7dec4385 docs: add placeholder for lua_spa_pod 2022-05-04 16:04:56 -04:00
Julian Bouzas
0bda5ca189 docs: remove deprecated doxygen configuration params 2022-05-04 15:47:08 -04:00