snapcast icon indicating copy to clipboard operation
snapcast copied to clipboard

Add documentation on using the source:tcp, especially with 'desktop' setups (e.g. pulse/pipe wire)

Open oliv3r opened this issue 2 months ago • 3 comments

Running snapcast on a server in the closet is great. I can do everything as it says on the box. However I sometimes also want to stream whats on my desktop. E.g. youtube, movie (audio only of course), whatever.

For this case, I'd need to use some 'tcp' (or udp) based connection. One barbaric way of doing so could be:

audio player software -> PulseAudio -> PulseAudio pipe sink -> socat remote:port snapfifo -> socat --server --port port snapfifo -> snapfifo -> snapserver -> network -> snapclient -> Alsa

(socat arguments are made up and for illustration purposes only.)

While it certainly may be possible to eliminate the server socat and directly connect to port 4593, it's an exersize left to the reader, as nothing is described here, just that snapserver can act as a server and client.

In that light, it could even be the case it would be possible to

audio player software -> PulseAudio -> PulseAudio pipe sink -> snaptcp-client -> snaptcp-server -> snapserver -> network -> snapclient -> Alsa

I suppose that doesn't require hard documentation per-say; but would be convenient.

Come to think of it, would it not be possible to directly output tcp data out of pulseaudio (or pipewire) directly to snapserver-tcp? I suppose it may require a special pulse/pipe plugin, we do want to be able to 'select' a specific output, to switch from local speakers to remote speakers; though I suppose that's a feature request on its own?

oliv3r avatar Apr 19 '24 21:04 oliv3r

Modern pipewire setups: https://github.com/badaix/snapcast/issues/821#issuecomment-1557312505

sixtyfive avatar Apr 22 '24 18:04 sixtyfive

Not sure that #821 is what I actually mean ;)

https://github.com/badaix/snapcast/discussions/1195 seems on one side more related though...

oliv3r avatar May 06 '24 21:05 oliv3r

A piece of documentation on how to have Linux + Mac + Windows + (modern) Linux + Android all stream/redirect their default audio outputs to the same Snapcast server would be great to have in any case!

sixtyfive avatar May 07 '24 10:05 sixtyfive