module-null-sink: how to allow reconfiguration of rates above 48 kHz?
Hi Pulseaudio developers! Pulseeffects dev here again because of that issue https://github.com/wwmm/pulseeffects/issues/709.
Up to now I had tested the null sink reconfiguration only with 44 kHz and 48 kHz. Resampling is avoided automatically. But for some reason I do not understand I see this in Pulseaudio logs when playing something at 96 kHz:
sink-input.c: Negotiated format: pcm, format.rate = "96000" format.sample_format = "\"float32le\"" format.channels = "6" format.channel_map = "\"front-left,front-right,rear-left,rear-right,front-center,lfe\""
sink-input.c: Trying to change sample spec
sink.c: Suspending sink PulseEffects_apps due to changing format, desired format = s32le rate = 48000
sink.c: PulseEffects_apps: suspend_cause: IDLE -> IDLE|INTERNAL
source.c: PulseEffects_apps.monitor: suspend_cause: IDLE -> IDLE|INTERNAL
source.c: Suspending source PulseEffects_apps.monitor due to changing format, desired format = s32le rate = 48000
source.c: Reconfigured successfully
Why is Pulseaudio assuming that the desired rate is 48 kHz? In the file daemon.conf
no default rate or alternate rate was manually specified and avoid-resampling
is enabled. When loading the null sink do I have to give a list of supported rates? I do not set any. I am trying something similar to this https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/blob/master/src/tests/passthrough-test.c#L148 but it just seem to be ignored.
Best regards, Wellington