Commit Graph

2419 Commits

Author SHA1 Message Date
George Kiagiadakis 994f1c1f4a Merge branch 'master' into next 2024-01-03 10:47:16 +02:00
Ferdinand Bachmann 3a40a8795b wpctl: resolve device id and route device internally 2023-12-27 19:36:56 +01:00
Ferdinand Bachmann f01177d08a wpctl: add set-route subcommand 2023-12-25 23:06:32 +01:00
Pauli Virtanen 88c59ff9c6 docs: explain runtime logging controls 2023-12-24 17:59:59 +02:00
Pauli Virtanen 43e190e3b4 wpctl: add set-log-level command
Add command for changing log level for Pipewire or Wireplumber daemons
at runtime.

It can be done with pw-metadata, but make it easier so that the user
doesn't need to look up Wireplumber client ids.
2023-12-24 17:59:59 +02:00
Pauli Virtanen 6037a6af94 m-log-settings: add module for changing log level at runtime
Pipewire server uses the global "settings" metadata for adjusting its
own log level.

Make it a convention that clients may watch "log.level" in this metadata
with their client id as subject, for setting their own log level
dynamically.

Watch the global "settings" metadata for "log.level" changes for our id.
On changes, set our log level accordingly.
2023-12-24 17:59:59 +02:00
Pauli Virtanen 4e17edb1ac wp: make wp_log_set_global_level public API
Applications may want to change WP log level at runtime.

Also change it to return error stataus instead of printing warnings on
error.
2023-12-24 17:58:30 +02:00
George Kiagiadakis c2d125b0da Merge branch 'master' into next 2023-12-23 18:34:00 +02:00
George Kiagiadakis f3f89b8fc1 docs: shuffle files to have the same logical hierarchy as on the generated doc
Also:
 - rename some files to remove redundant information from the filenames
 - rename many labels to match the filename and its place in the hierarchy
 - move lua_api under the scripting section
2023-12-23 12:36:27 +02:00
George Kiagiadakis 7dfc346a7b script docs: rewrite all csv-table to list-table for better source readability 2023-12-23 11:32:56 +02:00
George Kiagiadakis 6afdadc549 docs: update understanding_wireplumber.rst, merging changes from !535 2023-12-21 13:26:44 +02:00
George Kiagiadakis 59972b6e4f systemd: change the template services to load different profiles instead of conf files 2023-12-21 11:28:50 +02:00
George Kiagiadakis 0037733545 daemon: add cmdline option to load custom profile and report error if not found 2023-12-18 17:58:09 +02:00
George Kiagiadakis c0b212bb0e scripts: common-utils: do not crash if the defaults table is nil
Fixes #542, #544
2023-12-18 10:56:30 +02:00
George Kiagiadakis b58c94816a docs: update configuration.rst 2023-12-15 21:14:24 +02:00
George Kiagiadakis 6ace763868 docs: add central doc section about the configuration file 2023-12-15 21:07:02 +02:00
George Kiagiadakis 32b31232d1 docs: document components, profiles, features and settings 2023-12-14 16:49:12 +02:00
George Kiagiadakis 396b88e64b docs: update copyright years 2023-12-14 12:33:42 +02:00
George Kiagiadakis f63174ad5f docs: lua: document missing Core functions 2023-12-14 12:30:13 +02:00
George Kiagiadakis c4a0f5317e meson: exclude rst files from being installed with the scripts
and add them nicely to the sphinx_files without referencing '..' paths
2023-12-13 16:31:50 +02:00
Yaron Shahrabani 1e03b5bbe1 Added Hebrew translation. 2023-12-13 09:24:38 +00:00
Tom A. Wagner bae3381c76 meson: Set correct package version for generated .gir file for gobject introspection
Previously the package version used for the gir file was hardcoded and did not change
when the `wireplumber_api_version` definition was changed, which has now been fixed to
use that definition.
2023-12-12 12:13:51 +01:00
George Kiagiadakis ca3bc3eb6d scripts: tidy up monitor settings and config options
* add a new common-utils method to get configuration sections with
  defaults more efficiently and with less boilerplate
* rework the ALSA reserve-device settings so that the priority is
  configured per device using rules and the application name comes
  from the WpCore instead of the config file
* rename bluetooth to bluez in all options for consistency with other
  monitors that use the backend API name
* rename alsa.midi to alsa-midi for consistency with bluez-midi
2023-12-09 15:52:24 +02:00
George Kiagiadakis 4feebfc3a3 m-lua-scripting: add Core.get_properties() method 2023-12-08 12:28:24 +02:00
George Kiagiadakis 600adf003b scripts: tidy up device-related settings
* rename settings to make more sense
* split out monitor settings into a separate category
* add setting for restoring the default nodes in the node category
2023-12-08 12:06:28 +02:00
George Kiagiadakis d3eb77b292 release 0.4.17 2023-12-03 20:05:19 +02:00
George Kiagiadakis e193ae0efc policy-endpoint-device: handle filters only if we have endpoints
Otherwise the filters are handled both in policy-node and here
and everything is messed up

Fixes: #536
2023-12-03 19:46:20 +02:00
George Kiagiadakis 4cc387d81d object-manager: ref all object managers before exposing tmp globals
It is possible that during this process some object managers emit
their "installed" signal, and it is possible that some object managers
are destroyed within the handler of this signal, ending up with a dangling
object manager pointer (since we do not ref object managers in the registry)
and with a modified object_managers list during iteration...

Related to: #534
2023-12-02 11:32:17 +02:00
Wim Taymans a063d48281 scripts: pass is_filter to createLink
createLink uses an is_link variable that is unset. Fix this by passing
the is_link from the caller.
2023-11-29 11:01:34 +01:00
Wim Taymans e9fc965b32 scripts: log si_link after creating it
Or else we get a exception because it is nil.
2023-11-29 11:00:08 +01:00
Julian Bouzas 78fe6f1ef9 m-si-audio-adapter: make sure format task is finished even if ports were already configured
Currently, if the adapter node already has its ports configured when wireplumber
starts (For example a virtual node), the async _set_ports_format() call is never
completed because the node ports have not changed, stalling the event stack.
This fixes the issue by checking the Props param after configuring the ports,
and completes the task if there is one pending and the node already has ports
available.

Fixes #527
2023-11-28 10:59:15 +00:00
Danial Behzadi e0cb9a845f Update fa.po 2023-11-25 12:27:15 +00:00
George Kiagiadakis 0d249b8a13 release 0.4.16 2023-11-22 16:20:02 +02:00
George Kiagiadakis 0ac2947aed scripts: add new sm-objects script
This allows loading objects on demand by adding entries on the
"sm-objects" metadata object.

It is useful to dynamically load pipewire modules such as loopbacks
or network modules without having to start a new pipewire process with
a hardcoded config file.

It is also useful to load new metadata objects in order to implement
the singleton metatada concept as discussed in pipewire!1742

This may be expanded in the future to be able to load other types of
objects.

The key name, combined with the subject, is considered a unique id for
this instance of the object. The value should be a json object with
a 'type' specifying the type of object, together with a 'name' and 'args'
2023-11-22 08:38:36 +00:00
Ashok Sidipotu 256f60ebf2 policy-device-profile.lua: add a method to prioritize BT codecs. 2023-11-22 08:32:28 +00:00
Ashok Sidipotu a87d0478ea policy-endpoint-device.lua: connect filter output to actual sinks
The device script will also scan for the filter output streams and
connect them to the actual sink devices.
2023-11-22 08:22:59 +00:00
Ashok Sidipotu 9f6066ea0d policy-endpoint-device.lua: logic to connect endpoint to filter
While handling endpoints, first check to see if there is a filter
intending to connect to it.
Also prevent Endpoints connecting to filters unless otherwise
configured.
2023-11-22 08:22:59 +00:00
Ashok Sidipotu 83e990bf2d policy-endpoint-device.lua: enhance link log msgs 2023-11-22 08:22:59 +00:00
Ashok Sidipotu eba3d9d6f8 policy-endpoint-client.lua: avoid connecting filters to endpoints
Equalizer Node or filter nodes are considered as regular linkable and
its output is connected to endpoint. Prevent this by skipping over
filter nodes in this script.
2023-11-22 08:22:59 +00:00
George Kiagiadakis 5922f1f077 meson: bump the required pipewire version to 0.3.68
This is for the passive links behavioural change
2023-11-20 12:05:53 +02:00
George Kiagiadakis 0a7bd4fe86 si-standard-link: remove the "passive" property
PipeWire no longer uses the link.passive property, so there's no
point in adding it here. The node.passive property is used directly.
2023-11-20 12:00:54 +02:00
George Kiagiadakis 5b1ff7377f si-audio-endpoint: mark the nodes as passive instead of marking the links
This is a behavioural change in effect since pipewire 0.3.68, where
pipewire's link-factory ignores the link.passive property and the
node.pasive = in/out/true is used instead.
2023-11-20 11:56:07 +02:00
George Kiagiadakis 383b0e605d scripts: tidy-up linking related settings
* prefix all settings with just "linking."
* rename settings to make more sense
* fix the handling of the "follow" setting
* move the "move" handler to the rescan.lua script, as it's just a rescan hook
2023-11-19 18:34:33 +02:00
George Kiagiadakis 33fc476cb3 s-linking: always rescan when the default targets change
The "follow" setting was never really meant to disable reacting to
default target changes. It is also not meant to disable moving normal streams
to follow the default target. It is only meant to control whether streams
with a 'target.object' that matches the default target will move or not
to follow the default target changes (PulseAudio compat thing...)

Even if we leave this code here, disabling the "follow" option may disable
reacting to default target changes, but the streams will be moved anyway
when there is some other change in the graph (i.e. in the next rescan)
2023-11-19 17:52:20 +02:00
George Kiagiadakis 679d660058 settings: tidy up node-related settings
* prefix all settings with "node."
* move settings-stream.lua to settings-node.lua
* move the "audio-no-dsp" setting to the node settings
* add more settings related to node features
* split the default stream volume into 2 settings, one for playback
  streams and one for capture streams
2023-11-15 18:16:52 +02:00
George Kiagiadakis 2f071a67be scripts: rename all foo-config libs to settings-foo
And also use the term 'settings' everywhere instead of 'config' to refer
to the options managed by the WpSettings architecture
2023-11-15 15:44:01 +02:00
George Kiagiadakis beafcf1ac3 config: install commented-out conf files as examples in /usr/share/doc/wireplumber/examples 2023-11-15 15:44:01 +02:00
George Kiagiadakis 460e714a10 access-default: do not crash if the rules section is not defined in the config 2023-11-15 15:44:01 +02:00
George Kiagiadakis ab44996ce9 access-default: do not require the configuration file rules to operate 2023-11-15 13:37:33 +02:00
George Kiagiadakis cb243eea6d common-utils: avoid crashing when a rules section is not defined in the config 2023-11-15 12:57:41 +02:00