![]() |
CWCheckColors |
||||
Header: | CMApplication.h | Carbon status: | Supported | |
Tests a list of colors using a specified color world to see if they fall within the gamut of a destination device.
CMError CWCheckColors ( CMWorldRef cw, CMColor *myColors, UInt32 count, UInt32 *result );
A reference to the color world of type CMWorldRef describing how the test is to occur.
The functions NCWNewColorWorld and CWConcatColorWorld both allocate color world references of type CMWorldRef.
A pointer to an array containing a list of colors of type CMColor to be checked.This function assumes the color values are specified in the data color space of the source profile.
The number of colors in the array. This is a one-based count.
A pointer to a buffer of 32-bit data. On return, each 32-bit value is interpreted as a bit field with each bit representing a color in the array pointed to by myColors. You allocate enough memory to allow for 1 bit to represent each color in the myColors array. Bits in the result field are set to 1 if the corresponding color is out of gamut for the destination device. Ensure that the buffer you allocate is zeroed out before you call this function.
The result bit array indicates whether the colors in the list are in or out of gamut for the destination profile. If a bit is set, its corresponding color falls out of gamut for the destination device. The leftmost bit in the field corresponds to the first color in the list.
The color test provides a preview of color matching using the specified color world.
All CMMs must support the CWCheckColors function.
If you have set a profiles gamut-checking mask so that no gamut information is includedsee
The CWCheckColors function supports matching sessions set up with one of the multichannel color data types. CWCheckColors is not supported if the color world was initialized with a named color space profile.
Supported in Carbon. Available in Carbon 1.0.2 and later when ColorSync 1.0 or later is present.
© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)