godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.96k stars 20.18k forks source link

Godot editor window transparent and Vulkan error VK_NOT_READY and VK_ERROR_DEVICE_LOST #86560

Open Jelka33 opened 8 months ago

Jelka33 commented 8 months ago

Tested versions

Found in 4.2.1.stable.arch_linux

System information

Godot v4.2.1.stable unknown - Manjaro Linux #1 SMP PREEMPT_DYNAMIC Wed Dec 20 07:15:58 UTC 2023 - X11 - Vulkan (Forward+) - dedicated NVIDIA GeForce GT 710 (nvidia; 470.223.02) - Intel(R) Core(TM) i5-3570 CPU @ 3.40GHz (4 Threads)

Issue description

After waking system from suspend/sleep mode the editor window is completely black. When minimized and maximized again it is transparent and there's "ghost image" of anything that was on the current place of the window. The title bar is not transparent and the app is completely interactive (e.g. pop up windows could be opened, but also transparent). If the option for nVidia NVreg_PreserveVideoMemoryAllocations=0 is used (default value) the editor prints following errors in loop after wake up:

ERROR: Vulkan: Did not create swapchain successfully. Error code: VK_NOT_READY
    at: prepare_buffers (drivers/vulkan/vulkan_context.cpp:2459)
ERROR: Vulkan: Cannot submit graphics queue. Error code: VK_ERROR_DEVICE_LOST
    at: swap_buffers (drivers/vulkan/vulkan_context.cpp:2536)

If the options NVreg_PreserveVideoMemoryAllocations=1 NVreg_TemporaryFilePath=/nvidia-tmp are used there is no error, but the window is behaving the same.

Steps to reproduce

Minimal reproduction project (MRP)

Works literally with newly created project with nothing changed (not even a single scene)

largemanwo commented 7 months ago

Hey, I was getting the same error messages and having similar issues in my editor. I finally found this thread after running vulkaninfo in cmd and searching up the error messages I was getting in that. Not sure if you have Overwolf installed on your PC, but uninstalling it did the trick on mine!

If this doesn't help, something that will work albeit a compromise is switching your project to Compatibility mode. Might take a few tries being as you can't actually see the text in the menus lol but it should work!

Hope this helps!

voylin commented 2 weeks ago

I'm having the same issue when resuming from sleep that the editor is completely blank but the windows appear to exist as closing it whilst changes were present brings up the popup to first save, but the popup is also just completely blank.

Running Arch Linux lts with i3-wm