-
Notifications
You must be signed in to change notification settings - Fork 966
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
Disable Intel Fastclear in GL Backend #1645
Conversation
This works around a Mesa bug on Intel cards: - https://gitlab.freedesktop.org/mesa/mesa/-/issues/2565 - gfx-rs#1627 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks useful, thank you!
My main concern is - if it's temporary, when is it going to go away?
Do we have any means of detecting the driver version for Intel on EGL?
When we find a way to trick the driver into a slow clear, or otherwise work around the bug. Otherwise the when the bug is fixed. I'll have to check up on how to find driver versions, but it's likely there exists such an api. The big issue with this workaround is it needs to happen before LibGL is loaded at all. If we find a better workaround we can selectively apply it. |
eh, ok. Hope we can revert this soon :) |
You and me both :) |
Actually, the other way I found to work around the bug was to set Disadvantage there is that we are limiting functionality instead of making it slower. 🤔 Maybe that's better for some people, but not for others. I'm not sure. |
@zicklag so what that is likely doing is hitting a case where fast clears don't work so it's falling back to slow clears. I wonder if we can find another way to do that without affecting functionality. |
Not that this helps ( same alpha problem ), but I was also able to do it by forcing the pixel format of the framebuffer to As far as I know we only run into this with the draw framebuffer, and I can't remember if the user actually depends on it being a specific pixel format or not, I'd have to look at it again. |
This works around a Mesa bug on Intel cards:
Connections
Related to pixelated edges in GL backend brought up in #1627.
Description
This just adds the
INTEL_DEBUG=nofc
environment variable setting when creating anInstance
using the GL backend inwgpu_hal
. This is just a workaround until the mesa bug is fixed.I wanted to wait until adapters were enumerated to determine that the user wanted to use an Intel Mesa adapter, but the environment variable has to be set before the x11 display was opened so that wasn't an option.
This may not be the strategy we want to take with this one, but it seems relatively harmless. Because the environment variable prefixed with
INTEL
anyway, it might not effect devices other than the ones we want to, which would be good.Testing
I tested this on Ubuntu 20.04 with Mesa Intel(R) UHD Graphics (CML GT2) on using the GL backend.