Skip to content
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

Using virtual display causes stutter or freeze every 10 seconds (exactly) #179

Closed
Fel-the-Insane opened this issue Dec 30, 2024 · 8 comments

Comments

@Fel-the-Insane
Copy link

When using virtual display the stream will stutter/lag/freeze every 10 seconds, can count it out to the second every time.

This issue happens regardless of if I use moonlight or artemis client. It happens on both android and Xbox.

The only fix is to not use virtual display and to instead manually change resolution.

Notably I set up apollo on my sons gaming PC exactly the same and he has no issues.

My system has ryzen 9 7950x and rtx4070, my sons is a prebuilt INTEL with a 3060ti.

@ClassicOldSong
Copy link
Owner

ClassicOldSong commented Dec 30, 2024

Try set Adapter Name to your RTX 4070 and enable headless mode.

@Fel-the-Insane
Copy link
Author

Still happening with those changes unfortunately.

@ClassicOldSong
Copy link
Owner

hmmmm

Can you try disconnect your monitor physically and stream again?

@Fel-the-Insane
Copy link
Author

So that completely fixes it. But for obvious reasons I don't necessarily want to unplug my monitor from my PC every time I game stream haha. Any suggestions for what else I should do now, or why this happens?

@ClassicOldSong
Copy link
Owner

ClassicOldSong commented Jan 1, 2025

On Android, download the latest pre-release Artemis and choose Warp Drive in frame pacing might help. On other platforms there's no luck... I'm unsure about why this happens but my gut tells me it's a problem burying deep in the GPU core that can only be fixed by Nvidia. The thing is, when using a physical monitor, the clock signals is fetched from the monitor itself, but with a virtual monitor it's generated internally by your GPU or CPU. There's a mismatch between the two clocks and the hardware encoder gets confused. Your case might be an amplified version of what I tried to fix in the last build, but I failed because I then realized that it might be a hardware problem.

Some more things to try can be:

  1. Disable the physical monitor in Windows settings while streaming and see if it makes a difference
  2. Make sure the Adapter Name is set correctly: you can copy the name of your desired GPU for encoding from the results of dxgi-info.exe
  3. Use a different monitor
  4. Use headless mode and set Adapter Name to your iGPU, in this case it'll use your iGPU to encode which might workaround this problem, but it occupies PCIE bandwidth that might reduce some gaming performance. The good thing with this method is it actually frees computing power from your gaming GPU, so the results might vary.

@Fel-the-Insane
Copy link
Author

I think you're probably right about it being an NVIDIA thing and I appreciate your time helping me. As for the troubleshooting you suggested; nothing seemed to change anything except using a different monitor, and upon further investigation it seems that was only because I was using an HDMI cable for the other monitor. Having a DisplayPort used regardless of which port (iGPU or any of the 3 on graphics card) immediately makes the issue return.

So my final solution might just be getting a dummy plug and seeing if that has any different results than virtual display as I'm not willing to sacrifice my refresh rate by using HDMI on my monitor. I'll still use Apollo as well cuz you fixed that horrible issue on XBOX.

@ClassicOldSong
Copy link
Owner

It's not me fixed the xbox issue, it's @TheElixZammuto . Now the change made by him has merged to Sunshine, but it's in the pre-release only.

@Fel-the-Insane
Copy link
Author

Well thank you to them as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants