PATHMac OS 8 Developer Documentation > Mutlimedia and Graphics > ColorSync Manager >

Managing Color With ColorSync


Getting the Preferred CMM

Starting with ColorSync version 2.5, the ColorSync control panel lets a user choose a preferred CMM from any CMMs that are present, as described in Setting a Preferred CMM .

The ColorSync Manager provides the function CMGetPreferredCMM so that you can determine the preferred CMM in your code.


CMGetPreferredCMM

New in ColorSync 2.5

Identifies the preferred CMM specified by the ColorSync control panel.

pascal CMError CMGetPreferredCMM (
                     OSType *cmmType,
                     Boolean *preferredCMMnotfound)
cmmType
A pointer to an OSType . On return, the component subtype for the preferred CMM. For example, the subtype for ColorSync's default CMM is 'appl ' and the subtype for the Kodak CMM is 'KCMS' . A return value of NULL indicates the preferred CMM in the ColorSync control panel is set to Automatic, as described in Setting a Preferred CMM .
preferredCMMnotfound
A pointer to a Boolean flag for whether the preferred CMM was not found. On return, has the value true if the CMM was not found, false if it was found.
function result
A result code of type CMError . For possible values, see Result Codes for the ColorSync Manager .

The CMGetPreferredCMM function returns in the cmmType parameter a value that identifies the preferred CMM the user last specified in the ColorSync control panel. CMGetPreferredCMM returns false in the preferredCMMnotfound parameter if the preferred CMM is currently available and true if it is not. The preferred CMM may not be available, for example, because a user specifies a preferred CMM in the ColorSync control panel, then reboots with extensions off. ColorSync does not change the preferred CMM setting when the preferred CMM is not available.


© 1988-1999 Apple Computer, Inc. — (Last Updated 20 Jan 99)