GeorgeFilipkin / pulsemixer

CLI and curses mixer for PulseAudio

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

can program name be shown instead of "AudioIPC Server"?

wis opened this issue · comments

commented

Firefox' audio output appears as "AudioIPC Server: AudioStream", is there a general solution for all programs that have a separate audio thread/s / audio servers or it would require hard-coding program names?

here's the output of:

$ pactl list clients
 
Client #0
	Driver: module-systemd-login.c
	Owner Module: 20
	Properties:
		application.name = "Login Session 249"
		systemd-login.session = "249"

Client #1
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "Music Player Daemon"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		media.role = "music"
		application.icon_name = "mpd"
		application.process.id = "5106"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "mpd"
		application.language = "C"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"

Client #185881
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "Chrome input"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		application.process.id = "13405"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "chromium"
		application.language = "en_US.UTF-8"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"
		application.icon_name = "chromium"

Client #185889
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "mpv Media Player"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		application.process.id = "29139"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "mpv"
		application.language = "C"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"
		application.icon_name = "mpv"

Client #187743
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "pulsemixer"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		application.process.id = "21856"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "python3.7"
		application.language = "C"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"

Client #190084
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "AudioIPC Server"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		application.process.id = "16218"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "firefox"
		application.language = "en_US.UTF-8"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"
		application.icon_name = "firefox"

Client #190161
	Driver: protocol-native.c
	Owner Module: 12
	Properties:
		application.name = "pactl"
		native-protocol.peer = "UNIX socket client"
		native-protocol.version = "32"
		application.process.id = "10982"
		application.process.user = "auser"
		application.process.host = "archmachine"
		application.process.binary = "pactl"
		application.language = "en_US.UTF-8"
		window.x11.display = ":0"
		application.process.machine_id = "546c9574f539484aa460b73e76b3428a"
		application.process.session_id = "249"

should I contribute and add the option to display a more meaningful application.icon_name or application.binary for config specified list of application.name(s), which can be added with a key press to the config?

This should be taken to firefox bugzilla. They should give their sound subsystem proper application name instead of this AudioIPC. We can figure out a way to circumvent this in pulsemixer but other volume controls will still show this obscure name.

Actually, there are already multiple open issues about this:
https://bugzilla.mozilla.org/show_bug.cgi?id=1435614
https://bugzilla.mozilla.org/show_bug.cgi?id=1488666 (and apparently fix is in the works)

commented

I agree, however isn't a source renaming feature pretty useful?

It's a lot of work for a rare use-case. Can't just remap name to icon_name or binary. For example my firefox has no icon_name property. And binary can be arbitrary. To properly implement this renaming feature user needs to be given ability to specify which value goes into which property. If there is no property with a valid stream name then user has to be able to provide his own name. Something like this:

[application.name == "AudioIPC Server"] ; with regexps maybe?
application.name = "Firefox"
; application.name = application.process.binary
; application.name = application.process.icon_name
commented

check out my pull request: #40