Pulseaudio LADSPA EQ causes audio issues in Pidgin after recent update

Is this reproducible in other versions of Manjaro? I had not check this. (I’ve been too busy reinstalling Manjaro MATE over and over again!)

Recent updates had caused applications using ALSA for audio (like Pidgin) to have distorted audio. Why could this be?

Oh that’s great — the problem is intermittent, and sound is working correctly now. I’ll chime in if it’s a problem once more for me but for now it seems alright.

Sound issues only happen when there is no other audio. When there is another audio source transmitting sound ALSA applications (like Pidgin) exhibit no issues. So what’s being limited when there’s no sound?

If I select ALSA for audio playback in Pidgin, audio is still playing through Pulseaudio
(probably using one of the gst-plugins packages)

when ALSA is selected in Pidgin sound options, pacmd list-sink-inputs shows ALSA plugin in use

client: 72 <ALSA plug-in [pidgin]>
	properties:
		media.name = "ALSA Playback"
		application.name = "ALSA plug-in [pidgin]"

but if I select ‘Automatic’ in Pidgin, audio plays direct to Pulseaudio without need of a plugin

client: 81 <Pidgin>
	properties:
		media.name = "Playback Stream"
		application.name = "Pidgin"

both playback streams show the same volume levels and format

volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
	        balance 0.00
	muted: no

	sample spec: s16le 2ch 22050Hz
	channel map: front-left,front-right
	             Stereo

suggest you check both playback methods with

pacmd list-sink-inputs

if audio volume for ALSA plug-in is > 100% use the Reset button in Pidgin sound options to
reset to 100%

Here’s the thing — Pidgin doesn’t show with that command. But I think I found the problem.

    index: 121
        driver: <module-ladspa-sink.c>
        flags: START_CORKED 
        state: CORKED

The input is corked, which basically means the audio input isn’t open at all times. But because of said corking,(from my supposition) whenever there is a burst sound event like a notification PA doesn’t uncork in time for the sound to go through entirely, leading to garbled and incomplete playback.

I’ve dealt with PA issues with editing certain files before on Ubuntu, but audio corking was never a problem, rather it was microphone issues with boost not being adjustable in alsamixer. Gonna see what making the state not corked does for me.

Edit: Disabling cork plugin in default.pa didn’t resolve it.

Catching list-sink-inputs data is not easy on Pidgin. The command only recognises an active audio stream and the audio notifications in Pidgin are very short, so have to be quick to catch it (or use a longer audio file)

Pidgin using Method: ALSA
1 sink input(s) available.
    index: 496
	driver: <protocol-native.c>
	flags: 
	state: RUNNING
	sink: 1 <alsa_output.pci-0000_04_06.0.analog-stereo>
	volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
	        balance 0.00
	muted: no
	current latency: 181.43 ms
	requested latency: 64.00 ms
	sample spec: s16le 2ch 22050Hz
	channel map: front-left,front-right
	             Stereo
	resample method: speex-float-4
	module: 9
	client: 72 <ALSA plug-in [pidgin]>
	properties:
		media.name = "ALSA Playback"
		application.name = "ALSA plug-in [pidgin]"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "33"
		application.process.id = "45818"
		application.process.user = "nik"
		application.process.host = "gnomic"
		application.process.binary = "pidgin"
		window.x11.display = ":0.0"
		application.language = "en_GB.utf8"
		application.process.machine_id = "e1a1dbd021524f58a519eccfea07f8ea"
		application.process.session_id = "1"
		application.icon_name = "pidgin"
		module-stream-restore.id = "sink-input-by-application-name:ALSA plug-in [pidgin]"
Pidgin using Method: Automatic
index: 179
	driver: <protocol-native.c>
	flags: START_CORKED 
	state: RUNNING
	sink: 0 <alsa_output.pci-0000_04_06.0.analog-stereo>
	volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
	        balance 0.00
	muted: no
	current latency: 126.64 ms
	requested latency: 64.00 ms
	sample spec: s16le 2ch 22050Hz
	channel map: front-left,front-right
	             Stereo
	resample method: speex-float-4
	module: 9
	client: 16 <Pidgin>
	properties:
		media.name = "Playback Stream"
		application.name = "Pidgin"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "33"
		application.process.id = "89463"
		application.process.user = "nik"
		application.process.host = "gnomic"
		application.process.binary = "pidgin"
		window.x11.display = ":0.0"
		application.language = "en_GB.utf8"
		application.process.machine_id = "e1a1dbd021524f58a519eccfea07f8ea"
		application.process.session_id = "1"
		application.icon_name = "pidgin"
		module-stream-restore.id = "sink-input-by-application-name:Pidgin"

both of these work no problem for me on XFCE
Automatic option is showing START_CORKED but it has no effect on audio from notifications

suggest try temporarily removing module-suspend-on-idle
audio device may only be noisy due to return from suspend state

pacmd load-module module-suspend-on-idle

Yeah I legit can’t figure this out. I’m good at Linux, and I’ve shown some exemplary competency with certain subjects on here but PulseAudio – when it goes wrong — is above my pay grade.

I’ve disabled both corking and suspend on idle in default.pa and nothing changes with either ALSA or Automatic in Pidgin. Mind, none of thiis happens with the EQ turned off, and this never happens in the live session, in spite of using the same version, built with the same tarball.

I had also started fresh, with a formatted home and root part. After updating everything, the problem happens. And I really do not want to go through the effort of reinstalling again and installing packages one-by-one on a USB-attached media to figure it out.