diff options
author | Tim Angus <tim@ngus.net> | 2013-01-18 21:53:37 +0000 |
---|---|---|
committer | Tim Angus <tim@ngus.net> | 2014-08-28 10:59:21 +0100 |
commit | 39888c9d127f2792453a42bd1c3bbc4fadfc78da (patch) | |
tree | 6d5f79276dc3fb60f67d34b8b80d30eeb6badcfd /src/sdl | |
parent | 7bca93fc97ddef180acaae1d782c9e16cf35a0c9 (diff) |
Allow hardware gamma, in theory
Diffstat (limited to 'src/sdl')
-rw-r--r-- | src/sdl/sdl_glimp.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/sdl/sdl_glimp.c b/src/sdl/sdl_glimp.c index da29f704..fb40dbdc 100644 --- a/src/sdl/sdl_glimp.c +++ b/src/sdl/sdl_glimp.c @@ -762,18 +762,12 @@ void GLimp_Init( void ) ri.Error( ERR_FATAL, "GLimp_Init() - could not load OpenGL subsystem" ); success: - // This values force the UI to disable driver selection + // These values force the UI to disable driver selection glConfig.driverType = GLDRV_ICD; glConfig.hardwareType = GLHW_GENERIC; - // FIXME No SDL_SetGamma in SDL2? - /*glConfig.deviceSupportsGamma = SDL_SetGamma( 1.0f, 1.0f, 1.0f ) >= 0;*/ - - // Mysteriously, if you use an NVidia graphics card and multiple monitors, - // SDL_SetGamma will incorrectly return false... the first time; ask - // again and you get the correct answer. This is a suspected driver bug, see - // http://bugzilla.icculus.org/show_bug.cgi?id=4316 - /*glConfig.deviceSupportsGamma = SDL_SetGamma( 1.0f, 1.0f, 1.0f ) >= 0;*/ + // Only using SDL_SetWindowBrightness to determine if hardware gamma is supported + glConfig.deviceSupportsGamma = SDL_SetWindowBrightness( SDL_window, 1.0f ) >= 0; if ( -1 == r_ignorehwgamma->integer) glConfig.deviceSupportsGamma = 1; |