On Windows the gamma ramp for cards with 2d / 3d hardware can in general be set using the Win32 functions SetDeviceGammaRamp and GetDeviceGammaRamp. Some 3dfx cards, however, do not support these functions. As of December 1999, this category includes Voodoo 1, 2 and Rush. The current drivers for these cards export the WGL_3DFX_gamma_control extension; see the documents section of the site for more details. This code can be used to set gamma values using SetDeviceGammaRamp or wglSetDeviceGammaRamp3DFX: (Thanks to Pete Sebor for the original code for this. Any mistakes in this version are mine.) ---------------------------------------------------------------------- Gamma is a floating point number in the range (e.g.) 0.0f to 2.0f. pEntry is a WORD* pointer to one of the component gamma arrays (red, green or blue) for (dcSint32 idx=0; idx<256; idx++) { *pEntry = min(65535, max(0, pow((idx+1) / 256.0, Gamma) * 65535 + 0.5)); pEntry++; } ----------------------------------------------------------------------