We only need to resume the SUSPENDED node when it has !pause-on-idle.
So, set the need_resume flag when we suspend in that case.
Clear the flag in the next round and make sure we set the node to
running again. We don't need to clear any flags when the state change
completes anymore with this change.
This also fixes a case where strawberry would fail to configure the
correct sample rate. 44.1KHz would be used (the rate of the probe
stream) because the scheduler was thinking the node was still being
reconfigured because the reconfigure flag was only cleared when going
to the running state (an alsa sink has !pause_on_idle).
See #2929
This method can be used to access the param_changed method of the
underlying pw_stream.
Also adds new public functions rtp_stream_set_param and
rtp_stream_update_params which plum things through to pw_stream_set_param
and pw_stream_update_params respectively.
The RTSP FLUSH request does not seem to be required.
This change also fixes an issue where another RECORD request is
erroneously sent when the stream switches back from paused to streaming
by only setting `impl->streaming = false` in `rtsp_do_teardown()`.
Only schedule nodes together when there is just 1 capture and 1 playback
device. Devices might be mutually exclusive or require special setup
that would break otherwise.
See #3556
Add an option to automatically use snd_pcm_link when the follower clock
is matching the driver. Only set this to true in pro-audio and when
nodes are scheduled together.
See #3556
The `pipewire.*` properties may be set by clients but not changed by
them. However, how the checks are done now this allows e.g. connecting
clients to set `pipewire.access` themselves, which is not intended.
Fix the client property update check to not allow clients to set
pipewire.protocol/access, object.serial/id, pipewire.sec.* which are
supposed to be set by the server.
Decisions on whether an application is considered Flatpak sandboxed
should be in pw_check_flatpak.
Added the comment from 4169d9196d why we consider EACCES as
non-sandboxed. This is probably OK as it shouldn't occur on functioning
Flatpak setup.
This function was introduced in 52bd80aaa4 ("log: add topic loggers and a default topic")
but that commit made no use of it, and no subsequent commits ever
touched the function in any way.
No code in the repository, on debian codesearch, or on github uses it.
So remove it.
Instead of passing the pw_manager object, pass the client
object to the message handler. The client's manager can
still be accessed via `client->manager`. Furthermore,
message handlers now have access to `client->impl`.
Use `open_memstream()` to create a FILE stream and pass
that to message handlers to store their response. This allows
the `open_memstream()` calls and related error handling to be
removed from the message handlers.
`spa_streq()` already checks if any of its arguments
are NULL, and NULL is not considered equal to any non-NULL
string, therefore the check can be removed.
447ad35585 broken the default volume
controls because there were no instances of the nodes yet.
Fix this by always storing the control value in the first instance and
then duplicating it when we make other instances.
See #3434
Don't directly update the offset when not running. The running time
is position - offset and stays constant when not running.
Instead keep an extra elapsed variable that is updated when the state
is running. The offset is then always posision - elapsed. This is more
reliable and can compensate for jumps in the position timestamps.
Fixes#3544
See #3189
Do the volume settings after we have parsed all the properties.
Sync softMute with mute and set softVolume to 0.0 when the channelVolume
is zero (or muted).
See #3434
Scale the volume with min/max values.
Actually set the softMute and softVolume to false/1.0 and proxy the mute
and channelVolumes as they are.
Don't do anything special when we don't have custom volume ports.
See #3434