Replies: 22 comments 1 reply
-
👋 @azriel84, please edit your issue to complete the template with all the required info. Your issue will be automatically closed in 5 days if the template is not completed. Thanks. |
Beta Was this translation helpful? Give feedback.
-
Updated with correct host OS. Thanks! |
Beta Was this translation helpful? Give feedback.
-
logs? config? |
Beta Was this translation helpful? Give feedback.
-
Uploaded the logs from webui's troubleshooting section unless you need something else? As for config you need some file from the folder or the whole folder? |
Beta Was this translation helpful? Give feedback.
-
I can confirm that i am also experiencing microstutters, running Arch with Sway on Wayland. PC specs:
Logs:
|
Beta Was this translation helpful? Give feedback.
-
Disable VSYNC and Tripple buffering on your host computer NVIDIA Control Panel. You don't need this when streaming and it just creates issues and unnecessary input lag. Turn off GSYNC on your host if you have it enabled. Let Moonlight handle VSYNC of the stream. Enable VSYNC on the Moonlight app. I believe the IOS/tvOS version of Moonlight has VSYNC turned on by default. Go to your NVIDIA control panel and limit the global framerate to 60fps and set the video card power settings to maximum performance in case it's lowering the power draw when streaming. |
Beta Was this translation helpful? Give feedback.
-
I have already tried that with vsync and triple buffering off. No g-sync compatible screen here. Will update to the latest nightly though and follow your suggestion with the 60 fps frame limit again maybe this fixes things. There is no vsync option in tvOS you just set the frames (60 in my case) and I have also set apple tv to 60hz instead of 59,74 of the ntsc standard just in case... Will try everything again when I return home and respond. |
Beta Was this translation helpful? Give feedback.
-
I think you are confusing VSYNC with Variable Refresh Rate. Two different things. VSYNC and Tripple Buffering creates input lag on the stream, and it's not needed because Moonlight will handle the VSYNC part of your stream. Always leave those off on your host when streaming for the best experience. On your Apple TV make sure the frame pacing is set to smooth. |
Beta Was this translation helpful? Give feedback.
-
No VRR doesn't bother me both my monitor and TV do not support it so I play with 60 fps cap all the time but I was using vsync tbh. Will try with vsync off again and frame limiter and the 60hz option also in Apple TV's output. Maybe in my tests I missed a combination with vsync off that worked or a newer nightly handles things better. Frame pacing is always to smooth yeah, the other option didn't do anything anyway. DwmFlush enabled in Sunshine or disabled? |
Beta Was this translation helpful? Give feedback.
-
So, I tried your suggestions + vsync off in game settings. I observed an improvement in input lag as you said, but the stutters are still there. I dunno if I am nitpicking now or not... 4K streaming Stray should be something easy. I understand having problems with cyberpunk where streaming at 4K with RT psycho settings and DLSS 3 can be taxing for the system but I am having issues in relatively light games too, considering my graphics card. |
Beta Was this translation helpful? Give feedback.
-
Out of curiosity. Can you try streaming in 1080p on Moonlight and also reducing your in-game resolution to 1080p and see if the stutters go away. Try lowering the bitrate too if you have it too high. If the stutters go away, it may be that your router can't handle a 4k high bitrate stream. It goes without saying, but make sure your Apple TV is connected directly to your router through ethernet cable. |
Beta Was this translation helpful? Give feedback.
-
I know it can cause Steam Link works fine without stutters. Dunno what causes the issue in Moonlight with the exact same settings. AppleTV always on wire on a gigabit ethernet. Will try the 1080 or 1440p though just in case... |
Beta Was this translation helpful? Give feedback.
-
The other thing I can think of is GPU scheduling on windows. Go to graphic settings on windows > default graphics settings> , and turn off Hardware-accelerated GPU scheduling. That is known to cause stutters in games. By the way VSYNC and Tripple Buffering should be completely off on the NVIDIA control panel. (You mentioned in-game settings on your post) |
Beta Was this translation helpful? Give feedback.
-
VSYNC and Tripple Buffering are off on the nvidia control panel and in the in-game settings. Toggling GPU scheduling on/off didn't do anything but... Reducing Moonlight's stream resolution to 1440p instead of 4K solved everything, even in heavy games like Cyberpunk. Everything was buttery smooth. I continue to play the games at 4K on the host PC but Moonlight streams to the TV at 1440p and this solved everything. So the problem is clearly the handling of 4K stream. Now is it a router or a cpu/gpu issue? For example, Steam Link runs everything smooth at 4K stream in Stray but I get a "slow encoding" message in Cyberpunk and Plague Tale and of course low "encoded" fps and performance. Sunshine now handled Cyberpunk just fine along with all the other games in 1440p stream but stutters at 4K... Funny thing, Steam Link struggled even at 1440p in Cyberpunk whereas Sunshine handled the game excellent even on the p7 quality preset of HEVC! |
Beta Was this translation helpful? Give feedback.
-
Did some more testing this morning. 1440p stream with either 1440p/4K resolution in game, seems to solve the issues either with vsync on or off. Tripple buffering is always off. There is the case of Plague Tale Requiem which still stutters in 1440p, it's one of the heaviest and GPU taxing games out there so I guess the encoder struggles as well. Everything else works fine at 1440p and the stutters begin again at 4K streams. |
Beta Was this translation helpful? Give feedback.
-
Tested on Elden Ring too a relatively light game. Everything off, vsync, triple buffering had only the 60 fps cap on from Moonlight. Once again, every now and then microstutters at 4K stream, buttery smooth at 1440p. Same with Stray. |
Beta Was this translation helpful? Give feedback.
-
@azriel84 Can you try the suggestions mentioned here? I hav been wondering if the same bug exists in NVIDIA drivers in general but cannot replicate issue on my end anymore but it seems to match the same symptoms. |
Beta Was this translation helpful? Give feedback.
-
DX12 maybe the cause of these issues tbh, cause of the RT and DLSS I am testing at 4K. I will try using DX11 and 4K streams with your suggestions and see what will happen, but with DX12 games and lower resolutions all the issues quite dissapear as you mention. |
Beta Was this translation helpful? Give feedback.
-
It's not exclusive to DX12, it's just that the optimized full screen API is forced on DX12 games. DX11 games can use the same API, but it's optional. If you can confirm the issue goes away when setting NVIDIA energy profile to maximum performance, then I know it's the same issue and an NVIDIA bug basically. |
Beta Was this translation helpful? Give feedback.
-
I have already tried the maximum performance option and did nothing for the 4K stream. Just to make sure, you are suggesting to try 4K stream with windows or borderless window option to see if that's causing the issue? Tbh I was always trying every game with exclusive fullscreen or fullscreen, not window. |
Beta Was this translation helpful? Give feedback.
-
OK so, vsync off, frame cap via nvidia control panel off, power set to maximum performance and frame limit set to 60 fps via RTSS. Stutters again while streaming at 4K. When I droped the streaming resolution from Moonlight to 1440p everything were just fine (games running at 4K still). Windowed, borderless window, fullscreen and exclusive fullscreen, all had the same issue while streaming at 4K. So I guess as you say, it's an nVidia bug? |
Beta Was this translation helpful? Give feedback.
-
I just wanted to give my two cents, as a linux user with a 4090 that is facing this issue. I managed to make it a little better. I'm streaming HEVC content from Linux on a 4090 GPU and was experiencing max latency in the 80-90 ms range, which made games look choppy and micro-stuttery at any resolution. I was initially using the 560.35 open-source drivers. This is on KDE plasma + wayland. After switching to the closed-source Nvidia driver and adding the If you're facing similar issues, this might be worth trying. |
Beta Was this translation helpful? Give feedback.
-
Is there an existing issue for this?
Is your issue described in the documentation?
Is your issue present in the nightly release?
Describe the Bug
PC: 9900K, 16GB 3600/14 RAM, RTX 4080, running the latest stable and afterwards nightly build. Streaming on an Apple TV 4K 1st gen via Moonlight latest version (tvOS 16.3.1). Streaming at 4K/60 fps with v-sync and triple buffering on since my displays are 60Hz both PC monitor and oled TV and not g-sync compatible. Everything on default on Sunshine web settings.
Using both HEVC or h264, there are constant microstutters making the experience not fluid. No frame drops, steady 60 fps in every game tried with the 4080 (stray, shadow of the tomb raider, cyberpunk 2077, plague tale requiem). Disabling DwmFlush did make things somehow better but the stutters remain. Decreasing the resolution to 1440p didn't do anything neither increasing the CPU threads to 8 for the encoding process. I literally tried every combination of resolution, v-sync on/off/fast/adaptive, I always get some kind of stutter that I cannot get rid of. Steam Link has a ton of problems but it's buttery smooth with the exact same GPU settings so I guess either I am doing something wrong or it is a bug? Thanks in advance!
Expected Behavior
No microstutters during gaming.
Additional Context
No response
Host Operating System
Windows
Operating System Version
Window 10 22H2 OS build 19045.2546
Architecture
64 bit
Sunshine commit or version
latest nightly
Package
Windows - installer
GPU Type
Nvidia
GPU Model
Gigabyte RTX 4080 Gaming OC
GPU Driver/Mesa Version
528.49
Capture Method (Linux Only)
No response
Relevant log output
Beta Was this translation helpful? Give feedback.
All reactions