SelectiveColor method (ILEADRasterProcess)

Visual Basic example

Visual C++ example

 

Syntax

short SelectiveColor (ILEADRaster *pRaster);

Overview

Refer to Correcting Colors

Remarks

(Raster Pro and above toolkits) Changes the color of a bitmap by altering the definitions of one or more colors used by the bitmap.

Before you call the SelectiveColor method, you need to set the following Selective Colors properties:

SelectiveColorCyan property

SelectiveColorMagenta property

SelectiveColorYellow property

SelectiveColorBlack property

Selected colors are the additive colors (Red, Green and Blue), the subtractive colors (Cyan, Magenta and Yellow), the highlights (White), the midtones (Neutral) and the shadows (Black). Each of those "Selected Colors" has information about the percentages of cyan, magenta, yellow and black that constructs that selective color. Each unique pixel’s color can be defined as using some certain percentage of CMYK values. By changing the percentage of CMYK values for a "selected color", all colors related to that "selected color" would change also. For example, you can decrease the Magenta percentage from the "Blue selected color" to change a blue color to a color that is more similar to Cyan. Also you can increase the Yellow percentage from the "Magenta selected color" to change magenta color to a color that is more similar to Red.

You control the percentage of CMYK for each of the selected colors using the SelectiveColorCyan, SelectiveColorMagenta, SelectiveColorYellow, and SelectiveColorBlack properties. Each takes a value from –100 to 100. Negative values for any of these properties decreases the percentage of that color, whereas positive values increases the percentage of that color. SelectiveColorCyan = -100 it means no cyan will be used, whereas if SelectiveColorCyan = 100 it means the full percentage of cyan will be used. If a value is out of range, a negative value goes to -100 and a positive value goes to 100.

This method supports 48- and 64-bit color images. It does not support grayscale images. Support for 48- and 64-bit color images is available only in the Document/Medical toolkits.

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:

AutoColorLevel, ColorLevel, SelectiveColorCyan property, SelectiveColorMagenta property, SelectiveColorYellow property, SelectiveColorBlack property

Topics:

Raster Image Functions: Modifying Intensity Values