mirror of
https://github.com/glfw/glfw.git
synced 2026-09-21 08:39:45 +00:00
Win32: Disable fb transparency when it is broken
On Windows 7, when GLFW framebuffer transparency and the DWM are enabled but DWM transparency is disabled (i.e. when the Transparency setting is disabled under Personalization > Color), the contents of the framebuffer is combined with the last frame using additive blending instead of replacing the previous contents. This commit limits GLFW framebuffer transparency on Windows 7 to when DWM transparency is enabled, removing the previous workaround of setting a layered window color key that led to rendering artifacts. Fixes #1512.
This commit is contained in:
@@ -143,6 +143,8 @@ static GLFWbool loadLibraries(void)
|
||||
GetProcAddress(_glfw.win32.dwmapi.instance, "DwmFlush");
|
||||
_glfw.win32.dwmapi.EnableBlurBehindWindow = (PFN_DwmEnableBlurBehindWindow)
|
||||
GetProcAddress(_glfw.win32.dwmapi.instance, "DwmEnableBlurBehindWindow");
|
||||
_glfw.win32.dwmapi.GetColorizationColor = (PFN_DwmGetColorizationColor)
|
||||
GetProcAddress(_glfw.win32.dwmapi.instance, "DwmGetColorizationColor");
|
||||
}
|
||||
|
||||
_glfw.win32.shcore.instance = LoadLibraryA("shcore.dll");
|
||||
|
||||
Reference in New Issue
Block a user