gilbert189 — 5/18/2025, 3:02:08 AM

Turns out ZeroMQ exists and it’s very useful

# Now I only need the jukebox
while true; for f in (ls | shuf); sox $f -C 9 --comment "" -t ogg - pad 0 5; end; end | ffmpeg -readrate 1 -f ogg -i - -b:a 48k -f opus zmq:tcp://localhost:2763
↩ repost
gilbert189 — 4/23/2025, 5:23:42 PM

The efforts I have to make for a private “Internet radio”

# The jukebox 
for f in (ls | grep " " | grep -iv "compress" | shuf); sox $f -C 9 --comment "" -t ogg - pad 0 5; end | ffmpeg -readrate 1 -f ogg -i - -b:a 320k -f mpegts "udp://127.0.0.1:7060" 

# Meanwhile, in another SSH connection, the sound system
# (needed because SSH doesn't support UDP tunneling) 
while true; ffmpeg -v -8 -f mpegts -i "udp://127.0.0.1:7060" -f matroska -bufsize 3000k -c:a libopus "tcp://127.0.0.1:7070?listen"; end
♥ 3 ↩ 1 💬 0 comments
♥ 2 ↩ 0 💬 2 comments

comments

theglasspenguin:

your workload can either be 90% dependencies or 90% pure suffering, no in-between

5/18/2025, 4:08:41 AM
gilbert189:

i mean

one of the iterations of the soundsys pipes the stream of the jukebox to fdkaac first before ffmpeg

since someone maintaining the ffmpeg Arch package doesn’t build it with --enable-libfdk-aac and I want to use HE-AACv2 because the network on my boarding house can’t cope with a continuous 48 kbps Opus stream reliably

that’s another dependency =’)

5/18/2025, 9:00:20 AM