From 31fb726ab896ac96c64c844080cac1dac23d2c4a Mon Sep 17 00:00:00 2001 From: yvt Date: Mon, 6 May 2019 12:05:52 +0900 Subject: [PATCH] Fix colors being too dark on non-macOS platforms This commit fixes the issue by explicitly requesting a sRGB-capable default framebuffer. Fixes #827. --- Sources/Gui/SDLRunner.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/Sources/Gui/SDLRunner.cpp b/Sources/Gui/SDLRunner.cpp index 155d3c38c..c8e16011f 100644 --- a/Sources/Gui/SDLRunner.cpp +++ b/Sources/Gui/SDLRunner.cpp @@ -561,6 +561,7 @@ namespace spades { SDL_GL_SetAttribute(SDL_GL_DEPTH_SIZE, 0); if (!r_allowSoftwareRendering) SDL_GL_SetAttribute(SDL_GL_ACCELERATED_VISUAL, 1); + SDL_GL_SetAttribute(SDL_GL_FRAMEBUFFER_SRGB_CAPABLE, 1); /* someday... SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK,