Important: The information in this document is obsolete and should not be used for new development.
CMGetIndNamedColorValue
Obtains device and PCS color values for a specific named color index from a named color space profile.
pascal CMError CMGetIndNamedColorValue ( CMProfileRef prof, unsigned long index, CMColor *deviceColor, CMColor *PCSColor);
prof
- A profile reference (page 3-63) to a named color space profile to obtain color values from.
index
- A one-based index value for a named color.
deviceColor
- A pointer to a device color. On output, a device color value in CMColor union format. If the profile does not contain device values,
deviceColor
is undefined.PCSColor
- A pointer to a profile connection space color. On output, an interchange color value in CMColor union format.
- function result
- A result code of type CMError. See "Result Codes" (page 3-174) for a list of ColorSync-specific result codes.
DISCUSSION
Based on the passed named color index, the CMGetIndNamedColorValue function does a lookup into the named color tag and returns device and PCS values. If the index is greater than the number of named colors, CMGetIndNamedColorValue returns an error code.