A janky subsonic music player for endless random play.
Find a file
2024-12-10 16:37:18 +05:00
src FFT computation and value updating 2024-12-10 16:37:18 +05:00
.gitignore Add covert art rendering 2024-11-28 16:28:10 +05:00
Cargo.lock FFT computation and value updating 2024-12-10 16:37:18 +05:00
Cargo.toml FFT computation and value updating 2024-12-10 16:37:18 +05:00
README.md - Volume control 2024-12-10 14:09:28 +05:00

subtails

A janky subsonic terminal client.

This largely just exists because I wanted to play around with a TUI and try to mess with pipewire. This has been tested with gonic, and only works with 48kHz and 2 audio channel music files.

All it does is endlessly play random music from a given subsonic server like a radio. There is no seeking and no playlist functionality, just a play/pause toggle. ffmpeg is used to decode audio samples, since symphonia does not currently support the opus codec, which is 90% of what I need.

If for some absurd reason you want to actually use this (don't), ffmpeg must be accesible from $PATH, and a minimal config file is required, either in the working directory, or in ~/.config/subtails/. Said file must be named subtails.toml. UNIX is required (if pipewire wasn't clear enough).

Config

Configuration is done via a TOML file. Only for configuring the subsonic server info and player controls. The subsonic password can optionally be passed through an environment variable SUBSONIC_PASSWORD.

[subsonic]
server_address = "https://sub.so.nic" # absolute https address
username = "admin"                    # your subsonic username
password = "admin"                    # subsonic password, can be passed in via Env var

[controls]
# Values are defaults if left unspecified.
quit = 'q'                            # Quit
play_state_toggle = ' '               # Play/Pause
next = 'n'                            # Skip current song

Don't use this

I cannot stress enough how janky this is. Just don't use this. The audio controls and samples are sent on the same queue ffs. I might remake all of this with libmpv or mpv-ipc for a saner player at some point.