mastodon.xyz is one of the many independent Mastodon servers you can use to participate in the fediverse.
A Mastodon instance, open to everyone, but mainly English and French speaking.

Administered by:

Server stats:

874
active users

I'm trying to "cast" my laptop's screen (Debian+GNOME) to my living room TV, either to an HDMI dongle or to the RPi connecting to it (LibreElec+Kodi) *without* resorting to a Chromecast and ideally only using FOSS.

It's revealing to be surprisingly difficult. Any suggestions?

@zacchiro maybe obs to capture the desktop streaming to a local rtmp server, then something to play the stream? Searching suggests piping rtmpdump to vlc and that nginx or apache can handle streaming rtmp.

Also I bet gstreamer has a set of modules that could do it.

Some searching turned up this story of trying to do something like what you want and eventually creating a small program that streams a desktop over gstreamer rtsp
reddit.com/r/rust/comments/12h
Eventually he gets to a github project with that sets up the gstreamer to kodi daemon.

Looking up differences between rtmp and rtsp, rtsp probably has lower latency.

Last random idea would be a desktop streaming program like rustdesk

Stefano Zacchiroli

@alienghic more to the point, what would the "something to play the stream on Kodi" be?

@zacchiro

So I'd first try vlc for playing random stream urls.

I finally managed to stream a window from one computer to another using the docker image of
github.com/bluenviron/mediamtx

(I didn't feel like testing audio)

I setup obs to stream to the rtmp lister port on a computer running mediamtx.

I then connected to the HLS port with a web browser and slowly watched my edit some text in emacs.

I also had a few moments of working with obs streaming to a v4l2loopback-dkms video device and then streaming that "video camera" to another device using vlc, but it didn't keep working.

Maybe it'd be worth packaging mediamtx for debian?

Ready-to-use SRT / WebRTC / RTSP / RTMP / LL-HLS media server and media proxy that allows to read, publish, proxy, record and playback video and audio streams. - bluenviron/mediamtx
GitHubGitHub - bluenviron/mediamtx: Ready-to-use SRT / WebRTC / RTSP / RTMP / LL-HLS media server and media proxy that allows to read, publish, proxy, record and playback video and audio streams.Ready-to-use SRT / WebRTC / RTSP / RTMP / LL-HLS media server and media proxy that allows to read, publish, proxy, record and playback video and audio streams. - bluenviron/mediamtx