Possible create a CGamma class which could be used in isolation of the control, the control could also inherit from this class giving the developer a little more flexibility - just a thought. This is because Windows assumes a monitor with a gamma value of 2.2, the standard gamma value for Windows. In most cases, if a computer runs the Windows operating system, we can achieve close to ideal colors by using a monitor with a gamma value of 2.2. it would be good to be able to call a static Function to Set/Put a 0-100% of the gamma without using the dialog. The gamma relationship between the operating system and the LCD monitor. Use dialog to control setting visually, user clicks 'OK' allow application to static GetGammaPos and write to registry. User selects option to set gamma settings Get gamma registry setting - not there then call static gamma SetGammaPos(defaultPos)Įlse use gamma registry setting call SetGammaPos(RegistryPos) Maybe have a choice whether or not the dialog saves to the registry. We need to save current gamma for future restore. To change gamma, it is necessary to change the RGB value of each color contained in the buffer by a float factor between 0.0 and 2.0. In fact we need to have a 3 dimensional buffer of 256 WORD to manipulate gamma correction. Windows provides two APIs GetDeviceGammaRamp/ SetDeviceGammaRamp to perform gamma correction.
0 Comments
Leave a Reply. |