![]() |
CMMGetNamedColorName |
||||
Header: | CMMComponent.h | Carbon status: | Unsupported | |
Handles the kCMMGetNamedColorName request by returning a named color name from a named color space profile for a specific named color index.
CMError CMMGetNamedColorName ( CMMComponentInst cmm, CMProfileRef prof, UInt32 index, StringPtr name );
A handle to your CMMs storage for the instance of your component associated with the calling application or device driver.
A profile reference to a named color space profile.
An index value for a named color.
A pointer to a Pascal color name string. On output, it identifies the named color specified by index.
A CMM may respond to the kCMMGetNamedColorName request code, but it is not required to do so. Most CMMs can rely on the default CMM to handle this request code adequately. The ColorSync Manager sends this request code to your CMM on behalf of an application or device driver that called the CMMGetNamedColorName function. The ColorSync Manager dispatches this request to the Component Manager, which calls your CMM to service the request. A CMM that handles the kCMMGetNamedColorName request code typically responds by calling a CMM-defined function (for example, CMMGetNamedColorName).
Based on the passed color name index, the CMMGetNamedColorName function does a lookup into the named color tag of the profile whose reference is passed in the prof parameter and returns the name. If the index is greater than the number of named colors, CMMGetNamedColorName returns an error code.
CMMGetNamedColorName is an API to CMMs. Use CMGetNamedColorName instead. Application developers should avoid calling CMMs directly, since they may or may not support a given API.
© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)