Yellow-Dog-Man / Resonite-Issues

Issue repository for Resonite.
https://resonite.com
123 stars 2 forks source link

Desktop Duplication API Crash when removing display #727

Open kazu0617 opened 8 months ago

kazu0617 commented 8 months ago

Describe the bug?

When any display connects or disconnects after loading localhome, Resonite crashes immediately.

To Reproduce

  1. Connect multi display (at least 2),
  2. Launch Resonite.
  3. Wait until load localhome.
  4. disconnect display (if you use DP, just turn off that display).
  5. Crash.

Expected behavior

When I disconnect display, resonite doesn't crash.

Screenshots

No response

Resonite Version Number

2023.11.15.1158@2019.4.19f1

What Platforms does this occur on?

Windows

What headset if any do you use?

Anything. I test in VR(ALVR / Varjo / Vive)/Desktop

Log Files

HINATA-WIN - 2023.11.15.1158 - 2023-11-18 20_00_54.log

And here's crash files without dump. it seems this bug curse with "uDesktopDuplication.dll". error.log Player.log

Additional Context

This crash doesn’t show when disable desktop behavior, so i disable desktop function when i use screen mode. Config-DisableDesktop.json

Reporters

Resonite: kazu / litalita Discord: @kazu0617 / @litalita ( <@190137850698792961> / <@662107702633168916> ) GitHub: @ArchieTheRaccoon

989onan commented 8 months ago

I can confirm this works as someone with two monitors

Ardescar commented 8 months ago

This is related to this report. https://github.com/Yellow-Dog-Man/Resonite-Issues/issues/79

shiftyscales commented 7 months ago

@kazu0617 - thanks for the replication of this issue- I see that disabling the desktop view resolves the issue- so I agree with the suspicion it is related to the desktop duplication API that is used.

Ardescar commented 7 months ago

For me it only crashes when i remove a display. Adding one did sofar no crash.

But it happens sometimes and by accident that i crash resonite by switching my montor off.

kazu0617 commented 3 months ago

@Ardescar

For me it only crashes when i remove a display. Adding one did sofar no crash.

But it happens sometimes and by accident that i crash resonite by switching my montor off.

If you turn off the monitor, the crash is probably a mechanism that detects the on / off of the monitor in the display port and switches the connection. In a sense, it is normal, and resonite can cause crashes.

JackTheFoxOtter commented 3 months ago

This was the reason I had to disable my main DP monitor's auto-sleep, since everytime it went to sleep, Resonite would crash.

kazu0617 commented 3 months ago

@JackTheFoxOtter

This was the reason I had to disable my main DP monitor's auto-sleep, since everytime it went to sleep, Resonite would crash.

By loading config written in this issue, it will not crash without changing the display port settings. Resonite makes the desktop invisible, so it's a temporary measure, but you can check the desktop with other tools, so let's get this hard.

JackTheFoxOtter commented 3 months ago

@JackTheFoxOtter

This was the reason I had to disable my main DP monitor's auto-sleep, since everytime it went to sleep, Resonite would crash.

By loading config written in this issue, it will not crash without changing the display port settings. Resonite makes the desktop invisible, so it's a temporary measure, but you can check the desktop with other tools, so let's get this hard.

I'm aware, however disabling the in-game Desktop functionality isn't an option for me, as I use it a lot. Disabling auto-sleep of my monitor was the better option in my case, even if it results in unnecessary power draw.