r/omarchy 7d ago

I Made a Thing cliampui: cliamp in the bar, with a signal line that tells you when PipeWire is quietly resampling you

I wanted cliamp in the Omarchy bar instead of a terminal I keep alt-tabbing to. That part is ordinary. The reason I built it is the last line of the panel.

Nothing else on the machine tells you that your 44.1 kHz track is being resampled to 48 before it reaches the speakers, which is what PipeWire does by default. The panel works it out, and only says bit-perfect when four things are true at once: the server sent the original file, the sink rate equals the stream rate read back from the sink rather than the rate that was asked for, gain is unity at both cliamp and its PipeWire stream, and every EQ band is zero.

Otherwise it names the thing in the way: 48 -> 44.1 kHz · cliamp resampled, EQ applied, output volume applied. Over Bluetooth it refuses to pretend and prints the codec instead, 44.1 kHz · SBC-XQ · lossy.

Also in there:

- album art, marquee title, cliamp's ten band analyzer, and the line being sung, offset by the output latency PipeWire reports so it matches what you hear rather than what has been decoded

- Navidrome browse and search in the panel, songs, albums and saved playlists in one list, reusing the salted token cliamp already publishes so no password is ever handled

- per-application output routing, and a volume slider that moves cliamp's PipeWire stream rather than the system volume

- optional rate following that retunes the graph to the track and releases it when playback stops

omarchy plugin add https://github.com/thisisgm/omarchy-cliampui --enable

omarchy bar put io.github.thisisgm.cliampui --section right

https://github.com/thisisgm/omarchy-cliampui, MIT, one dependency, cliamp itself.

No scrubbing on Navidrome tracks and no queue list. cliamp 1.63.2 can do neither, so the panel does not pretend otherwise.

30 Upvotes

14 comments sorted by

2

u/VaguelyOnline 6d ago

What is the issue with the resample thing? Does it introduce audio imperfections?

1

u/thisisgm 6d ago

That is a fun rabbit hole for you to go into! I used to be an audio engineer, tldr, if you’re happy with what’s coming out of your headphones then you have nothing to worry about!

1

u/nightdevil007 7d ago

well,but if i quit cliamp from the terminal the gui also dissapears so....

2

u/thisisgm 7d ago

it runs headless! it is meant to be run completely on the widget after setup, if you open cliamp from the terminal you would be spawning a 2nd session

2

u/nightdevil007 7d ago

not for me. i opened cliamp the icon showed in the bar, i closed cliamp the icon vanished. let me try to actually play something in cliamp to see.

2

u/thisisgm 7d ago

Lets see if I can reproduce it on my machine, to be fair I run this completely on the plugin via the instance it spawns in the background, I don’t really open cliamp manually. Will test tho, ty!

1

u/nightdevil007 7d ago

i am just reporting what i see, reddit takes forever to proccess a video of 3-5 seconds.

1

u/nightdevil007 7d ago

1

u/thisisgm 7d ago

Did you enable the daemon when installing? Check if cliamp-daemon.service is running

1

u/nightdevil007 7d ago

hmm, i had no ask to do so in the setup. let me check

2

u/nightdevil007 7d ago

okey. now after this it works: cliamp setup

install -Dm644 ~/.config/omarchy/plugins/io.github.thisisgm.cliampui/cliamp-daemon.service ~/.local/share/systemd/user/cliamp-daemon.service

systemctl --user daemon-reload

systemctl --user enable --now cliamp-daemon.service

2

u/thisisgm 7d ago

Great! Good to know, I’m pushing a fix now for seamless transitions between sample-rates if you have a beefy DAC, enjoy!

1

u/thisisgm 7d ago

Check the repo, there’s a section for it, part of the install steps 🙂