Re: [GD-Windows] GetDeviceGammaRamp() is lieing to me
Brought to you by:
vexxed72
From: brian h. <bri...@py...> - 2002-12-04 03:03:32
|
Which operating system? > In my program, I call GetDeviceGammaRamp() to read the user's > active gamma settings. Then, if there's not "sufficient" gamma > adjustment, I set my own gamma ramp with SetDeviceGammaRamp(). > When the program exits, I restore the ramp I read back from > GetDeviceGammaRamp() on start-up. > > Unfortunately, it appears that the device is lieing to me. I > get the data as such: > > WORD userRamp[ 768 ]; > HDC dc = CreateDC( "DISPLAY", 0, 0, 0 ); > GetDeviceGammaRamp( dc, userRamp ); > > What ends up happening is that I always get back some "default" > gamma ramp with a little bit of compensation; I apply my own > ramp, and then on shutdown I set the ramp "back" to some very > low gamma setting. > > If I go into my display control panel settings and crank the > gamma way up (both "game gamma" and "desktop gamma"), then > starting my program will still retrieve the same "default" gamma > ramp, apply its ramp (which is dimmer), and on shutdown, set the > screen to a very dim setting. > > This is on a Radeon 9700, though I've heard similar problems > from users with nVIDIA hardware as well. > > What's going on? > > / h+ |