Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Advanced Color Imaging Reference /
Chapter 4 - ColorSync Manager Reference for Color Management Modules / Constants


Optional Request Codes

Your CMM should respond to the ColorSync Manager request codes defined by the following enumeration, but it is not required to do so. For a description of how your CMM can respond to ColorSync Manager requests from the Component Manager, see "Developing Color Management Modules" in Advanced Color Imaging on the Mac OS.

The ColorSync Manager defines the following optional request codes:

enum {
   kCMMMatchPixMap         = 3,  /* match colors of pixel map image */
   kCMMCheckPixMap         = 4,  /* gamut-check pixel map colors */
   kCMMConcatenateProfiles = 5,  /* concatenate profiles (for backward
                                    compatibility with ColorSync 1.0) */
   kCMMConcatInit          = 7,  /* init prior to concat color worlds */
   kCMMValidateProfile     = 8,  /* validate profile elements */
   kCMMMatchBitmap         = 9,  /* match colors of bit map image */
   kCMMCheckBitmap         = 10, /* gamut-check bit map colors */ 
   kCMMGetPS2ColorSpace    = 11, /* get PostScript color space */
   kCMMGetPS2ColorRenderingIntent= 12,/* get PostScript rendering intent */
   kCMMGetPS2ColorRendering= 13, /* get PostScript color rendering
                                    dictionary */
   kCMMFlattenProfile      = 14, /* extract data from profile */
   kCMMUnflattenProfile    = 15, /* create file for unflattened data */
   kCMMNewLinkProfile      = 16, /* create linked profile */
   kCMMGetPS2ColorRenderingVMSize= 17,/* get PostScript version 2 color rendering
                                    dictionary virtual memory size */
   kCMMGetNamedColorInfo   = 70, /* get named color information */
   kCMMGetNamedColorValue  = 71, /* get color values for a named color */
   kCMMGetIndNamedColorValue= 72,/* get index for a named color */
   kCMMGetNamedColorIndex  = 73, /* get named color index from name */
   kCMMGetNamedColorName   = 74  /* get named color name from index */
};
Constant descriptions

kCMMMatchPixMap
In response to this request code, your CMM must match the colors of the pixel map image pointed to by the myPixMap parameter to the gamut of the destination device, replacing the original pixel colors with their corresponding colors as specified in the data color space of the destination device's color gamut. To perform the matching, you use the profiles specified by a previous kNCMMInit, kCMMInit, or kCMMConcatInit request to your CMM. For more information about how your CMM should respond to this request code, see the MyCMMatchPixMap function (page 4-27).
kCMMCheckPixMap
In response to this request code, your CMM must check the colors of the pixel map image pointed to by the myPixMap parameter against the gamut of the destination device to determine if the pixel colors are within the gamut of the destination device and report the results. To perform the check, you use the profiles specified by a previous kNCMMInit, kCMMInit, or kCMMConcatInit request to your CMM. For more information about how your CMM should respond to this request code, see the MyCMCheckPixMap function (page 4-30).
kCMMConcatenateProfiles
This request code is for backward compatibility with ColorSync 1.0.
kCMMConcatInit
In response to this request code, your CMM should initialize any private data your CMM will need for a color session involving the set of profiles specified by the profile array pointed to by the profileSet parameter. Your function should also initialize any additional private data needed in handling subsequent calls pertaining to this component instance. For more information about how your CMM should respond to this request code, see the MyCMConcatInit function (page 4-25).
kCMMValidateProfile
In response to this request code, your CMM should test the profile whose reference is passed in the prof parameter to determine if the profile contains the minimum set of elements required for a profile of its type. For more information about how your CMM should respond to this request code, see the MyCMMValidateProfile function (page 4-17).
kCMMMatchBitmap
In response to this request code, your CMM must match the colors of the source image bitmap pointed to by the bitmap parameter to the gamut of the destination device using the profiles specified by a previous kNCMMInit, kCMMInit, or kCMMConcatInit request to your CMM. For more information about how your CMM should respond to this request code, see the MyCMMatchBitmap function (page 4-18).
kCMMCheckBitmap
In response to this request code, your CMM must check the colors of the source image bitmap pointed to by the bitmap parameter against the gamut of the destination device using the profiles specified by a previous kNCMMInit, kCMMInit, or kCMMConcatInit request to your CMM. For more information about how your CMM should respond to this request code, see the MyCMCheckBitmap function (page 4-22).
kCMMGetPS2ColorSpace
In response to this request code, your CMM must obtain or derive the color space element data from the source profile whose reference is passed to your function in the srcProf parameter and pass the data to a low-level data-transfer function supplied by the calling application or device driver. For more information about how your CMM should respond to this request code, see the MyCMMGetPS2ColorSpace function (page 4-34).
kCMMGetPS2ColorRenderingIntent
In response to this request code, your CMM must obtain the color-rendering intent from the header of the source profile whose reference is passed to your function in the srcProf parameter and then pass the data to a low-level data-transfer function supplied by the calling application or device driver. For more information about how your CMM should respond to this request code, see the MyCMMGetPS2ColorRenderingIntent function (page 4-37).
kCMMGetPS2ColorRendering
In response to this request code, your CMM must obtain the rendering intent from the source profile's header and generate the color rendering dictionary (CRD) data from the destination profile, and then pass the data to a low-level data-transfer function supplied by the calling application or device driver. For more information about how your CMM should respond to this request code, see the MyCMMGetPS2ColorRendering function (page 4-39).
kCMMFlattenProfile
In response to this request code, your CMM must extract the profile data from the profile to flatten, identified by the prof parameter, and pass the profile data to the function specified in the proc parameter. For more information about how your CMM should respond to this request code, see the MyCMMFlattenProfile function (page 4-45).
kCMMUnflattenProfile
In response to this request code, your CMM must create a temporary file in which to store the profile data you receive from the low-level data-transfer function supplied by the calling application or driver. Your function must return the file specification. For more information about how your CMM should respond to this request code, see the MyCMMUnflattenProfile function (page 4-47).
kCMMNewLinkProfile
In response to this request code, your CMM must create a single device-linked profile of type DeviceLink that includes the profiles passed to you in the array pointed to by the profileSet parameter. For more information about how your CMM should respond to this request code, see the MyCMNewLinkProfile function (page 4-33).
kCMMGetPS2ColorRenderingVMSize
In response to this request code, your CMM must obtain or assess the maximum virtual memory (VM) size of the color rendering dictionary (CRD) specified by the destination profile. You must return the size of the CRD for the rendering intent specified by the source profile. For more information about how your CMM should respond to this request code, see the MyCMMGetPS2ColorRenderingVMSize function (page 4-42).
kCMMGetNamedColorInfo
In response to this request code, your CMM extracts named color data from the profile whose reference is passed in the srcProf parameter. For more information, see the MyCMMGetNamedColorInfo function (page 4-50).
kCMMGetNamedColorValue
In response to this request code, your CMM extracts device and profile connection space (PCS) color values for a specific color name from the profile whose reference is passed in the prof parameter. For more information, see the MyCMMGetNamedColorValue function (page 4-51).
kCMMGetIndNamedColorValue
In response to this request code, your CMM extracts device and PCS color values for a specific named color index from the profile whose reference is passed in the prof parameter. For more information, see the MyCMMGetIndNamedColorValue function (page 4-53).
kCMMGetNamedColorIndex
In response to this request code, your CMM extracts a named color index for a specific color name from the profile whose reference is passed in the prof parameter. For more information, see the MyCMMGetNamedColorIndex function (page 4-54).
kCMMGetNamedColorName
In response to this request code, your CMM extracts a named color name for a specific named color index from the profile whose reference is passed in the prof parameter. For more information, see the MyCMMGetNamedColorName function (page 4-55).

Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 NOV 1996