LightControl method (ILEADRasterProcess)
Overview |
Refer to Changing Brightness and Contrast |
Remarks
Lightens or darkens all or part of a bitmap by remapping the pixel values.
This method remaps the pixel values of the bitmap across the full range of available pixel values, in order to achieve the values set in the LightLowerAvr, LightAvr and LightUpperAvr properties.
For example, call this function for a grayscale bitmap, with LightAvr containing 150, LightLowerAvr containing 100 and LightUpperAvr containing 190. The pixels of the bitmap will be remapped so that the new average pixel value for the entire bitmap will be 150, the new average value for those pixels with a value between 0 and the average value for the entire bitmap will be 100, and the new average value for those pixels with a value between the average value for the entire bitmap and the maximum pixel value in the bitmap will be 190.
This method supports 12 and 16-bit grayscale and 48 and 64-bit color images. Support for 12 and 16-bit grayscale and 48 and 64-bit color images is available only in the Document/Medical toolkits.
For an example, see the following figure:
The following figure shows the same bitmap, after the effect has been applied:
To obtain this effect, the following settings were used with the function:
LightLowerAvr = 100
LightAvr = 255
LightUpperAvr = 255
lFlags = YUV_SPACE
This method does not support signed data images. It returns the error code ERROR_SIGNED_DATA_NOT_SUPPORTED if a signed data image is passed to this method.
See Also
Elements: |
LightUpperAvr property, LightLowerAvr property, LightAvr property |
Topics: |