|
|
|
|
SetGammaCorrectData
Programs the hardware gamma correction table.
Declaration
void NAPI GA_driverFuncs::SetGammaCorrectData(
GA_palette *pal,
N_int32 num,
N_int32 index,
N_int32 waitVRT)
Prototype In
snap/graphics.h
Parameters
pal |
Pointer to the gamma data to program |
num |
Number of gamma entries to program |
index |
Index of first entry to program |
waitVRT |
Wait for vertical retrace flag |
Description
This function programs the gamma correction tables for 15 bit and above graphics modes. The gamma correction tables are used in these graphics modes to adjust the response curves of each of the three color guns for color matching purposes. The gamma correction tables are assumed to be 256 entries deep with three independent channels for each of red, green and blue. Each value in the gamma tables are 8-bits wide, with a range of 0 to 255. Gamma correction data is passed to the function in an array of GA_palette structures, similar to the SetPaletteData function.
The wait for vertical retrace flag is used to synchronize the palette update with the start of the vertical retrace. The following are valid values:
value |
Description |
0 |
Change palette immediately not 0 - Program palette during vertical retrace period |
However if you are changing palette values at the same time as swapping display pages, you may want to disable vertical retrace synching and program the palette entries directly after swapping display pages. Generally you need to synchronize with the vertical retrace while programming the palette to avoid the onset of snow (or interference on the screen).
Note: If this hardware does not support gamma correction, this function will be a NULL pointer.
See Also
GetPaletteData, SetPaletteData, GetGammaCorrectData, SetGammaCorrectDataExt, GetPaletteDataExt, SetPaletteDataExt, GetGammaCorrectDataExt
Copyright © 2002 SciTech Software, Inc. Visit our web site at http://www.scitechsoft.com