mirror of
https://github.com/glfw/glfw.git
synced 2026-09-17 22:32:50 +00:00
Made gamma ramp functions per-monitor.
This commit is contained in:
@@ -150,6 +150,8 @@ GLFWAPI int glfwInit(void)
|
||||
|
||||
GLFWAPI void glfwTerminate(void)
|
||||
{
|
||||
int i;
|
||||
|
||||
if (!_glfwInitialized)
|
||||
return;
|
||||
|
||||
@@ -157,6 +159,13 @@ GLFWAPI void glfwTerminate(void)
|
||||
while (_glfw.windowListHead)
|
||||
glfwDestroyWindow((GLFWwindow*) _glfw.windowListHead);
|
||||
|
||||
for (i = 0; i < _glfw.monitorCount; i++)
|
||||
{
|
||||
_GLFWmonitor* monitor = _glfw.monitors[i];
|
||||
if (monitor->rampChanged)
|
||||
_glfwPlatformSetGammaRamp(monitor, &monitor->originalRamp);
|
||||
}
|
||||
|
||||
_glfwDestroyMonitors();
|
||||
|
||||
_glfwPlatformTerminate();
|
||||
|
||||
Reference in New Issue
Block a user