-
-
Notifications
You must be signed in to change notification settings - Fork 153
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
Skybox shader corruption on linux #77
Comments
I believe this is a depth stencil or depth buffer related issue, you may need to use a Vulkan capabilities tool or debug mode to find out what mode Acid is selecting:
If your GPU only supports Acid/Sources/Graphics/Images/Image.cpp Line 164 in 45e1b31
I don't know if a stencil aspect bit is optional with |
Sure thing I'll rig together a test in a few hours yet! Thank you for the quick followup. |
I checked the mesa source code for RADV, all depth stencils listed are supported. I believe the stencil aspect bit is required in this case. |
|
I set VK_FORMAT_D32_SFLOAT_S8_UINT as the only try format and the background still presents corruption. I ensured that it was actually set as VK_FORMAT_D32_SFLOAT_S8_UINT by printing the expected and found enumerated values. Funny thing is It terminates as expected when I put VK_FORMAT_D24_UNORM_S8_UINT but not VK_FORMAT_D16_UNORM or VK_FORMAT_D16_UNORM_S8_UINT, just treats them like they have a stencil bit! |
I'm running over it in a RenderDoc capture. The 2D depth map seems okay (Doesn't seem to "drift" like I'm seeing). |
Sorry if I'm being extremely slow to fix this bug, shadows and skybox severely need a rewrite anyways. A RenderDoc capture would be very helpful, I am getting other kinds of artifacts using Mesa on a laptop with integrated Intel graphics. |
Whoa, good to hear at least that you can reproduce, thought my setup was insane. Will post once home, my card is a polaris10. |
https://drive.google.com/open?id=1a_xqfcyjaOPzS5Wt2LT_Q2pYTc2d1Ymn PBR test renderdoc on a wx7100 mobile GPU, polaris10. I dragged the camera as the trace capture wipes all but the last overlay of the corruption so you can clearly see it. |
It's not utterly crippling but the engine's stability under mesa is a bit worrying. |
Messed around disabling code and it looks like the skybox issue is a problem with fog. Once I disable fog in the physics test render it isn't an issue. Not sure if the shader is borked or the Vulkan compliance but hopefully I can nail it down. |
Got schooled up on Vulkan a bit more and enabled standard validation layers and I think I found the problem. Full log attached here: |
Fixed! Sources/Graphics/Renderpass/Framebuffers.cpp Looks like certain formats aren't available to me here? Know why this is the case on linux/mesa? I now get |
Okay, took a look through the mesa src/amd/vulkan/ tree. Looks like VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL isn't actually available as a format under radv or anv even though its enumerated in the basic vulkan includes. I assume it would be better to add a check here to see if this format is available before use between GENERAL and OPTIMAL. |
Describe the bug
The skybox of my test builds has major corruption that is cut through by the on screen models.
The corruption seems to pulsate in color.
To Reproduce
Not sure what's the cause yet...
Expected behaviour
A clear view into the skybox without the slowly pulsating color.
Screenshots
Hardware:
Gentoo linux kernel 5.2.10, AMD WX 7100, RADV
Additional context
I am using Mesa ACO git but I have tested with the LLVM compiler and ACO both and I get the same odd behavior.
The text was updated successfully, but these errors were encountered: