![]() |
CMGetCWInfo |
||||
Header: | CMApplication.h | Carbon status: | Supported | |
Obtains information about the color management modules (CMMs) used for a specific color world.
CMError CMGetCWInfo ( CMWorldRef cw, CMCWInfoRecord *info );
A reference to the color world of type CMWorldRef about which you want information.
The functions NCWNewColorWorld and CWConcatColorWorld both allocate color world references of type CMWorldRef.
A pointer to a color world information record of type CMCWInfoRecord that your application supplies. On return, the ColorSync Manager returns information in this structure describing the number of CMMs involved in the matching session and the CMM type and version of each CMM used.
This discussion is accurate for versions of ColorSync prior to 2.5. See the version notes below for changes starting with version 2.5.
To learn whether one or two CMMs are used for color matching and color checking in a given color world and to obtain the CMM type and version number of each CMM used, your application must first obtain a reference to the color world. To obtain a reference to a ColorSync color world, you (or some other process) must have created the color world using the function NCWNewColorWorld or the function CWConcatColorWorld.
The source and destination profiles you specify when you create a color world identify their preferred CMMs, and you explicitly identify the profile whose CMM is used for a device link profile or a concatenated color world. However, you cannot be certain if the specified CMM will actually be used until the ColorSync Manager determines internally if the CMM is available and able to perform the requested function. For example, when the specified CMM is not available, the default CMM is used.
The CMGetCWInfo function identifies the CMM or CMMs to use. Your application must allocate a data structure of type CMCWInfoRecord and pass a pointer to it in the info parameter. The CMGetCWInfo function returns the color world information in this structure. The structure includes a cmmCount field identifying the number of CMMs that will be used and an array of two members containing structures of type CMMInfoRecord. The CMGetCWInfo function returns information in one or both of the CMM information records depending on whether one or two CMMs are used.
Starting with ColorSync 2.5, a user can select a preferred CMM with the ColorSync control panel. If the user has selected a preferred CMM, and if it is available, then it will be used for all color conversion and matching operations.
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)