itsmikethetech / Virtual-Display-Driver

Add virtual monitors to your windows 10/11 device! Works with VR, OBS, Sunshine, and/or any desktop sharing software.
https://vdd.mikethetech.com/
3.33k stars 134 forks source link

When I start a game in Windows 11 it changes the desktop resolution #133

Closed Funk3 closed 1 month ago

Funk3 commented 2 months ago

Hello!

I am currently using moonlight and sunshine to play games from my TV and my Steam Deck. I use 2 resolutions which is

3840x2160 1280x800

I have it set up so when I stream to my PC with moonlight, it streams to the virtual display and the resolution is at 1280x800 (can confirm via display settings on my primary monitor).

However, whenever I start a game, my monitor flashes, and the resolution changes to 3840x2160 and the game starts playing at that resolution. I have scoured moonlight and sunshine documentation to see where I am going wrong, and I can only assume VDD or Windows 11 is the culprit.

My Specs are:

Windows 11 23H2 Ryzen 7 5800x RTX 3080 AlienWare AW3420DW

I have reinstalled my virtual display drivers, I have removed image scaling on my nvidia control panel. I have uninstaled geforce experience. I have removed full screen optimizations on games compatibility properties. Pls help

itsmikethetech commented 2 months ago

My assumption is that the game may have a default resolution set. The solution would be to either adjust the game specific settings within the game itself, or perhaps removing all unused resolutions from the virtual display driver, forcing the game to use that resolution.

Funk3 commented 2 months ago

That's a fair assumption. I have tested 2 games that have done this to me which is

Cyberpunk 2077 v2.0 Subnautica

The only problem is that I have 2 resolutions that I use. Would the easiest solution to have 2 virtual monitors and have my programs only open up to that virtual monitor with 1 resolution?

itsmikethetech commented 2 months ago

Ah, that is a concern. Sure, two displays would work for that if it's not too much work to add to the configs. I've seen people use ResX to switch resolution on launch, but without a script to update the game config it would likely still override and try to switch back.

Funk3 commented 2 months ago

I am currently going down that rabbit hole and hopefully that works! I will also look at ResX as well

Funk3 commented 2 months ago

I found out the issue! (In case anyone else has this issue)

It appears HDR being on wanted to keep it at the 4k resolution, as I turned it off for the steamdeck, it works flawlessly.

zjoasan commented 2 months ago

If understood you correctly, you have to change the VDD to disable hdr in order to get it to change of res on the steamdeck stream"?

I've got a few powershell scripts laying for simpple disable and enable hdr or another script to change orientation etc etc. still discussion if we should redistibute em, since some of them need admin privs.

Funk3 commented 2 months ago

AFfirmative. Disabling HDR is the only way to "keep" the 1280x800 resolution streaming to my steamdeck.

zjoasan commented 2 months ago

Then you could call the scripts, in the start cmd for the games, and just make two apps. CoDTV and CoDSD and do some HDR dis/en-able, Resolution-changes for specific device...

But right now the scripts are written for the latest beta. And I'm unsure if i signed the ones github

Nonary commented 2 months ago

You really should be keeping the resolution on host at 4k, even if the client is 1280x800 though

Funk3 commented 2 months ago

I find that it messes games up where I can't change the aspect ratio, like cyberpunk. Games like yakuza and horizon forbidden west are fine though

Nonary commented 2 months ago

I find that it messes games up where I can't change the aspect ratio, like cyberpunk. Games like yakuza and horizon forbidden west are fine though

Add 3840x2400 to the monitor, install https://github.com/Nonary/ResolutionAutomation and add an override for 2560x1600x60=3840x2400x60 (or change the refresh to 90 instead of 60 if using OLED edition)

And then configure Moonlight to stream at 2560x1600; you will notice a significant quality increase in terms of sharpness and clarity compared to streaming at 1280x800

Funk3 commented 2 months ago

I am actually already using the Resolution Automation script, I will change the resolution. Thanks!

Funk3 commented 2 months ago

I find that it messes games up where I can't change the aspect ratio, like cyberpunk. Games like yakuza and horizon forbidden west are fine though

Add 3840x2400 to the monitor, install https://github.com/Nonary/ResolutionAutomation and add an override for 2560x1600x60=3840x2400x60 (or change the refresh to 90 instead of 60 if using OLED edition)

And then configure Moonlight to stream at 2560x1600; you will notice a significant quality increase in terms of sharpness and clarity compared to streaming at 1280x800

Just wanted to say that I have done this and tried out 3 games that I knew would give me issues, and they worked perfectly! Especially Cyberpunk 2077. Thank you very much!