From f2d4b4c9248cb05ccc385356f54fe8f707ec27e4 Mon Sep 17 00:00:00 2001 From: gewlitys Date: Mon, 10 Mar 2003 16:54:59 +0000 Subject: [PATCH] Gamma correction is now only adjusted if --gamma is given (fixes #245), from chmmravatar git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@881 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/src/starcon2.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sc2/src/starcon2.c b/sc2/src/starcon2.c index 2b4df1f45..daadcad8a 100644 --- a/sc2/src/starcon2.c +++ b/sc2/src/starcon2.c @@ -89,6 +89,7 @@ main (int argc, char *argv[]) int val; char contentdir[1000]; float gamma = 1.0; + int gammaset = 0; enum { @@ -229,6 +230,7 @@ main (int argc, char *argv[]) break; case 'g': sscanf(optarg, "%f", &gamma); + gammaset = 1; break; case CSCAN_OPT: if ((val = Check_PC_3DO_opt (optarg, @@ -320,7 +322,8 @@ main (int argc, char *argv[]) init_communication (); TFB_InitGraphics (gfxdriver, gfxflags, width, height, bpp); - TFB_SetGamma (gamma); + if (gammaset) + TFB_SetGamma (gamma); TFB_InitSound (snddriver, soundflags); TFB_InitInput (TFB_INPUTDRIVER_SDL, 0);