comparison src/video/SDL_gamma.c @ 1695:7179cb72dbba SDL-1.3

Date: Fri, 9 Jun 2006 11:35:23 +0300 From: "Janne Junnila" Subject: [SDL] SDL_SetGamma bug You can't set the the gamma 'brighter' than 1.0. There's a patch attached.
author Sam Lantinga <slouken@libsdl.org>
date Tue, 20 Jun 2006 06:51:23 +0000
parents 8e754b82cecc
children 0b1070f2f94d
comparison
equal deleted inserted replaced
1694:7b19e09f5481 1695:7179cb72dbba
49 ramp[i] = 0; 49 ramp[i] = 0;
50 } 50 }
51 return; 51 return;
52 } else 52 } else
53 /* 1.0 gamma is identity */ 53 /* 1.0 gamma is identity */
54 if (gamma >= 1.0f) { 54 if (gamma == 1.0f) {
55 for (i = 0; i < 256; ++i) { 55 for (i = 0; i < 256; ++i) {
56 ramp[i] = (i << 8) | i; 56 ramp[i] = (i << 8) | i;
57 } 57 }
58 return; 58 return;
59 } else 59 } else