From: havoc Date: Fri, 21 Jan 2005 03:34:22 +0000 (+0000) Subject: if hardware gamma setting fails, try to restore system gamma anyway (Windows stupidity) X-Git-Tag: xonotic-v0.1.0preview~5201 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=55a5c1810b8e3f9930a760363e4872b52f397c14;p=xonotic%2Fdarkplaces.git if hardware gamma setting fails, try to restore system gamma anyway (Windows stupidity) git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4948 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/vid_shared.c b/vid_shared.c index eeac1c57..a9ea605c 100644 --- a/vid_shared.c +++ b/vid_shared.c @@ -918,6 +918,9 @@ void VID_UpdateGamma(qboolean force) } Cvar_SetValueQuick(&vid_hardwaregammasupported, VID_SetGamma(vid_gammaramps)); + // if custom gamma ramps failed (Windows stupidity), restore to system gamma + if(!vid_hardwaregammasupported.integer) + VID_SetGamma(vid_systemgammaramps); } else {