Multiple allowed sample rates + virtual surround sink = loss of audio output
- PipeWire version: 0.3.68
- Distribution and distribution version: Debian GNU/Linux 12 (bookworm)
- Desktop Environment: GNOME
- Kernel version): 6.1.0-7-amd64
Description of Problem:
Allowing multiple sample rates while using virtual-surround-sink causes issues, potentially leading to loss of audio output.
How Reproducible:
100% if following steps below
Steps to Reproduce:
- Set
default.clock.allowed-rates = [ 44100 48000 ]
in pipewire.conf - Add a virtual-surround-sink
- Restart PipeWire
systemctl --user restart pipewire
- Run pw-top and observe while doing following steps
- Play any 44.1khz content (I play music in Rhythmbox) to make the audio chain switch to 44.1khz and then stop.
- In pw-top, effect_output.virtual-surround-7.1 is now stuck at a rate of 44100.
- Play any 48khz content (I use video in MPV) and note in pw-top that the rates displayed do not match, and the audio is completely gone
Actual Results:
Complete loss of audio and effect_output.virtual-surround-7.1 stuck at the wrong sample rate.
Expected Results:
Sample rates should switch back and forth seamlessly without loss of audio, and since we stopped playing the 44.1khz content before starting the 48khz content, there should be no simultaneous mismatch of sample rates displayed in pw-top, i.e. effect_output.virtual-surround-7.1 should switch back to 48khz rather than being stuck at 44.1khz.
Additional information
Here are my specific configuration files. The virtual-surround-sink is slightly different from PipeWire's sample config but I don't know if it matters. Specifically, it has IR's for both sample rates and I've added an extra convolution step to correct the frequency response for my headphones. pipewire.conf sink-virtual-surround-7.1-hd555.conf