-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sunshine alters the refresh rate of displays it is not using #3591
Comments
Could you please post verbose logs and do the following steps:
I'll check the logs tomorrow. |
Stopped and re-started Sunshine service. Verbose Log attached. |
So, it seems that Windows API reports the refresh rate as:
Which is simply 60Hz... What if you disable the resolution change option? |
It is simply the way Windows API works. It stores the information about primary display alongside the resolution and refresh rate and there simply is no way to change primary display without touching these other settings. It is possible to tell Windows that we are virtual refresh rate-aware, but I don't know if it will work out-of-the-box. |
So it seems like Sunshine needs to be aware that the refresh rate returned by the Windows API may not actually be the actual setting in Windows Settings for that display. Because refresh rates in the running state can vary. The current process seems to read the refresh rate via API, and then when Sunshine is changing the Primary monitor, it uses that value from the API and changes the setting on the display - even in cases when it shouldn't like we are seeing here. |
Yes. Unless you tell Windows explicitly that you are aware of the virtual refresh rate, it will convert the information into the format that would be usable to you. Sadly my display does not support this virtual refresh rate, but if you would build Sunshine yourself, I could tell you how to enable it and test it, if you want. |
Happy to give it a try - are there build instructions anywhere? |
Also - if it's in the code already, could this be a flag (checkbox) in Sunshine - something like "enable Dynamic Refresh support (yes/no)" ? |
https://docs.lizardbyte.dev/projects/sunshine/latest/md_docs_2building.html Be sure to checkout the branch/commit of interest though. |
It depends on what will this new flag do. The last one that was added for Win10 required almost a complete rewrite of the existing algorithm... |
terrific... seems simple enough. However... why am I doing this again? What will be different about the build (or are you going to have me change something)? |
There's are really simple change that might enable virtual refresh rate support, however it could also be a waste of time if it's not as simple as a single switch. It's up to you. |
I'm happy to do the build - but wouldn't it be faster for you to make the change, build and drop the executable in a share someplace (since you are already set up)? |
Sure, I can prepare the build maybe tomorrow or sometime this week. I'll ping you when it's ready. |
super, happy to be a guinea pig :) |
Please try a build from here FrogTheFrog#7 and post the verbose logs whatever the outcome is. |
Sorry I thought you were going to build it and post the .exe for me to download. |
|
https://github.com/FrogTheFrog/Sunshine/actions/runs/12998913973?pr=7#artifacts Note: the link will change for different job runs |
Well, unfortunately this is as much as I can help you right now. Everywhere in the logs never anything resembling 144Hz is mentioned once. It could be another hidden API or something (based on the fact that scaling API that W10+ uses is not even available yet) or it is bug... The later can be checked by you - if you manually switch the primary display, will it still say 144 Hz everywhere on the window from your screenhot? On the button, in the "Display information" panel. |
Is there an existing issue for this?
Is your issue described in the documentation?
Is your issue present in the latest beta/pre-release?
None
Describe the Bug
I have a Vidtual Display set up and Sunshine is configured to use only that display (by its GUID). I have also configured Sunshine to NOT change the refresh rate of any display.
However, when my client connects (and Sunshine automatically makes the Virtual Display the "primary" as it should), the physical display on my PC changes from 144Hz to 60Hz. This should not happen because (a) this is not the display that Sunshine is working with and (b) I told Sunshine not to change any refresh rates.
After existing the session I have to manually re-set the physical display to 144Hz.
Expected Behavior
Expected behavior is for Sunshine to only apply any display settings (from the client, etc.) to the display it is configured to use. Also expect Sunshine to not change settings it is configured to not change.
Additional Context
No response
Host Operating System
Windows
Operating System Version
11 24H2
Architecture
amd64/x86_64
Sunshine commit or version
2025.122.141614
Package
Windows - installer (recommended)
GPU Type
AMD
GPU Model
NVidia RTX 3060Ti
GPU Driver/Mesa Version
566.36
Capture Method
None
Config
Apps
Relevant log output
The text was updated successfully, but these errors were encountered: