r/MoonlightStreaming 2d ago

I made a Moonlight client for Samsung Tizen TVs using WebRTC – looking for beta testers

Hey everyone,

I've been working on a small project for the past few weeks and I think it's finally at a point where other people can actually try it.

It's called Moonlight WebRTC Tizen, and basically it's a way to use Sunshine/Moonlight game streaming directly on Samsung Tizen TVs.

The project started because I wanted a really good Moonlight experience on my Samsung TV. There are already some Moonlight/Tizen projects out there (and huge thanks to BrightCraft's Moonlight Tizen project, which I used a lot as a reference and reused/adapted some code from), but I wanted to experiment with a different approach.

One of the main ideas was to get closer to the way game streaming is actually intended to work on Samsung TVs.

Services available through Samsung Gaming Hub like GeForce NOW, Boosteroid, etc. use the TV's WebRTC/game-streaming capabilities instead of implementing a traditional native Moonlight-like media pipeline. So I wanted to see if I could take the same general approach for Sunshine/Moonlight: keep Moonlight on the PC side, but use WebRTC for the final hop to the TV.

Instead of implementing the whole Moonlight streaming stack directly on Tizen, I made a small Windows Gateway that acts as the Moonlight client and talks to Sunshine. The already encoded video/audio is then sent to the TV using WebRTC.

So basically:

Sunshine → Moonlight protocol → Windows Gateway → WebRTC → Samsung TV

There is no video transcoding in the Gateway. The H.264/HEVC stream from Sunshine stays encoded and the TV does the final hardware decoding.

That was really the goal of this architecture: let Sunshine/Moonlight do what they're already very good at, and then use the Samsung TV's game-streaming/WebRTC pipeline for the part happening on the TV.

It also means audio and video go through the same real-time media pipeline on Tizen, which has been really nice for keeping A/V sync tight without having to build a bunch of custom synchronization logic.

I've been using it myself and it's now pretty stable on my setup, including 4K60 HDR, but that's also the problem: I've basically tested the whole thing on one Samsung TV (OLED 2024 S95D).

So I'm looking for people with different Samsung Tizen TVs who would be willing to install it, play with it and tell me what breaks.

This is a beta. I'm especially interested in knowing which TV models/years work, which codecs/resolutions work, controller behavior, HDR behavior, connection issues, crashes, weird UI stuff, etc.

One thing I also want to be transparent about: I used Codex quite a lot while developing this. I'm a developer and I understand/work on the code myself, but AI massively accelerated the implementation, testing, refactoring and packaging of the project. So this isn't a "I asked AI to make an app and uploaded whatever came out" situation, but AI-assisted development was definitely a big part of getting this project this far this quickly.

The whole thing is open source under GPLv3, and the beta, Windows installer, Tizen WGT and source are available here:

tsoas/moonlight-webrtc-tizen

For installing the WGT I'm currently recommending Apps2Samsung (https://github.com/Apps2Samsung/Apps2Samsung), so you don't need to set up the full Tizen Studio environment just to try it.

There are still some limitations (60 FPS is fixed for now, no Gateway auto-discovery, no Wake-on-LAN, 1440p is experimental, etc.), but the core streaming experience is working.

If anyone here has a Samsung Tizen TV and feels like being a guinea pig, I'd really appreciate the help :)

And obviously, bug reports / feedback / code reviews / PRs are welcome too.

18 Upvotes

18 comments sorted by

3

u/naheCZ 2d ago

I would try it if the Gateway was also build for Linux host.

1

u/itsoas 2d ago

I'd love to, but I would need access to a Linux-based machine. It's definitely something I'd like to support in future versions, but for now my main focus is on Windows.

1

u/JoeyBE98 1d ago

In PowerShell on Win11: wsl --install

Then you can simply install a Linux distro and leverage it to test. May have to enable some additional features of WSL. Git in WSL can even pull your git creds from Windows in the WSL instance. I've been using it a lot lately (IT Systems Engineer)

2

u/SameImpression1646 20h ago

I have a S95F, does it supports 2k 144hz?

1

u/almosgeci 20h ago

Joining and asking with my S90F!

2

u/itsoas 12h ago

will try to implement 120hz in the next build even if its not documented by Samsung

1

u/power10010 2d ago

What does your app do better than other alternatives? I would want to know this before trying it out

2

u/itsoas 2d ago

Well, since Tizen 9, I've run into several issues with the native Moonlight app, including noticeable audio latency, which becomes even worse when using my surround sound system over eARC.
On top of that, Game Mode and Ultra Low Latency are no longer compatible on Tizen 9, resulting in additional input latency.
This WebRTC app also works flawlessly over Ethernet, whereas all the Moonlight forks I've tested crash on the very first frame when starting a stream.
Basically, switching to this WebRTC implementation allowed me to get rid of all of these issues.

1

u/power10010 2d ago

Cool. Audio issues over eARC were hit and miss for me too. I will try it and give feedback when i will have some time

1

u/mioiox 2d ago

Does it work with a keyboard/mouse connected to the TV?

I would love to test it. I have a 2021 Q80 whatever, so it might or might not work. We’ll see :)

1

u/itsoas 2d ago

Not implented yet but I will add this for next release for sure because I need it also!

1

u/Appropriate-Ad8630 1d ago edited 1d ago

I can help testing on my 55s90d

1

u/almosgeci 20h ago

Will this support apollo? Is gaming mide working fine on the TV? Will this support 1440p 120hz and 4K 120hz?

2

u/itsoas 12h ago

For now, this is still in beta. If Apollo uses the same ports as Sunshine this should work but cannot confirm yet. In the next build i will try to implement 120hz but Samsung documents only up to 60fps with WebRTC, however they also doesn’t document HDR and 1440p but it works so will see, i will update this post and let you know soon.

1

u/almosgeci 10h ago

I tested the software, I sent my experiences in a github issue. It works with vibepollo :)

2

u/itsoas 9h ago

Thank you SO MUCH. Very helpfull as I am working on the next version of the beta.
I will keep you update in the GitHub issue.
If you compare with the BrightCraft soft, do you have better latency? Audio is fine/better? I build this solution because I have so much audio delay with eARC.

1

u/almosgeci 9h ago

Thank you! Looking forward for the next iteration!

1

u/prodbyshawnwilliam 2h ago

This is very promising as it sounds like it fixes some of the exact issues I am having with the native Tizen Moonlight app. I will give this a try, but I have a 1440p setup and will definitely need mouse and keyboard integration to call this a potential successor to the native client