mirror of
https://github.com/gwm17/glfw.git
synced 2024-11-26 20:28:49 -05:00
parent
5ca875a7ff
commit
5bbb837635
|
@ -97,6 +97,8 @@ GLFW bundles a number of dependencies in the `deps/` directory.
|
|||
- [Win32] Bugfix: Context re-creation was not triggered by sRGB hint
|
||||
- [Win32] Bugfix: Full screen windows were incorrectly sized and placed on some
|
||||
systems
|
||||
- [Win32] Bugfix: Gamma ramp functions acted on entire desktop instead of the
|
||||
specified monitor
|
||||
- [X11] Added run-time support for systems lacking the XKB extension
|
||||
- [X11] Made GLX 1.3 the minimum supported version
|
||||
- [X11] Replaced `XRRGetScreenResources` with `XRRGetScreenResourcesCurrent`
|
||||
|
|
|
@ -290,13 +290,8 @@ void _glfwPlatformGetGammaRamp(_GLFWmonitor* monitor, GLFWgammaramp* ramp)
|
|||
{
|
||||
HDC dc;
|
||||
WORD values[768];
|
||||
DISPLAY_DEVICEW display;
|
||||
|
||||
ZeroMemory(&display, sizeof(DISPLAY_DEVICEW));
|
||||
display.cb = sizeof(DISPLAY_DEVICEW);
|
||||
EnumDisplayDevicesW(monitor->win32.name, 0, &display, 0);
|
||||
|
||||
dc = CreateDCW(L"DISPLAY", display.DeviceString, NULL, NULL);
|
||||
dc = CreateDCW(L"DISPLAY", monitor->win32.name, NULL, NULL);
|
||||
GetDeviceGammaRamp(dc, values);
|
||||
DeleteDC(dc);
|
||||
|
||||
|
@ -311,7 +306,6 @@ void _glfwPlatformSetGammaRamp(_GLFWmonitor* monitor, const GLFWgammaramp* ramp)
|
|||
{
|
||||
HDC dc;
|
||||
WORD values[768];
|
||||
DISPLAY_DEVICE display;
|
||||
|
||||
if (ramp->size != 256)
|
||||
{
|
||||
|
@ -324,11 +318,7 @@ void _glfwPlatformSetGammaRamp(_GLFWmonitor* monitor, const GLFWgammaramp* ramp)
|
|||
memcpy(values + 256, ramp->green, 256 * sizeof(unsigned short));
|
||||
memcpy(values + 512, ramp->blue, 256 * sizeof(unsigned short));
|
||||
|
||||
ZeroMemory(&display, sizeof(DISPLAY_DEVICEW));
|
||||
display.cb = sizeof(DISPLAY_DEVICEW);
|
||||
EnumDisplayDevicesW(monitor->win32.name, 0, &display, 0);
|
||||
|
||||
dc = CreateDCW(L"DISPLAY", display.DeviceString, NULL, NULL);
|
||||
dc = CreateDCW(L"DISPLAY", monitor->win32.name, NULL, NULL);
|
||||
SetDeviceGammaRamp(dc, values);
|
||||
DeleteDC(dc);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user