Important: The information in this document is obsolete and should not be used for new development.
Summary of the Color Management Modules
Constants
enum { CMMInterfaceVersion= 1 }; /* request codes (required) */ enum { kCMMInit = 0, kCMMMatchColors= 1, kCMMCheckColors= 2 kNCMMInit = 6, }; /* request codes (optional) */ enum { kCMMValidateProfile = 8, kCMMFlattenProfile = 14, kCMMUnflattenProfile = 15, kCMMMatchBitmap = 9, kCMMCheckBitmap = 10, kCMMMatchPixMap = 3, kCMMCheckPixMap = 4, kCMMConcatenateProfiles = 5, kCMMConcatInit = 7, kCMMNewLinkProfile = 16, kCMMGetPS2ColorSpace = 11, kCMMGetPS2ColorRenderingIntent = 12, kCMMGetPS2ColorRendering= 13, kCMMGetPS2ColorRenderingVMSize = 17 };Functions
Required Functions
pascal CMError MyNCMInit (ComponentInstance CMSession, CMProfileRef srcProfile, CMProfileRef dstProfile); pascal CMError MyCMMatchColors(ComponentInstance CMSession, CMColor *myColors, unsigned long count); pascal CMError MyCMCheckColors(ComponentInstance CMSession, CMColor *myColors, unsigned long count, long *result); pascal CMError CMInit(ComponentInstance CMSession, CMProfileHandle srcProfile, CMProfileHandle dstProfile)Optional Functions
pascal CMError MyCMMValidateProfile ( ComponentInstance CMSession, CMProfileRef prof, Boolean *valid); pascal CMError MyCMMatchBitmap(ComponentInstance CMSession, const CMBitmap *bitmap, CMBitmapCallBackUPP progressProc, void *refCon, CMBitmap *matchedBitmap); pascal CMError MyCMCheckBitmap(ComponentInstance CMSession, const CMBitmap *bitmap, CMBitmapCallBackUPP progressProc, void *refCon, CMBitmap *resultBitmap); pascal CMError MyCMConcatInit (ComponentInstance CMSession, CMConcatProfileSet *profileSet); pascal CMError MyCMMatchPixMap(ComponentInstance CMSession, PixMap *myPixMap, CMBitmapCallBackUPP progressProc, void *refCon); pascal CMError MyCMCheckPixMap(ComponentInstance CMSession, const PixMap *myPixMap, CMBitmapCallBackUPP progressProc, BitMap *myBitMap, void *refCon); pascal CMError MyCMNewLinkProfile (ComponentInstance CMSession, CMProfileRef *prof, const CMProfileLocation *targetLocation, CMConcatProfileSet *profileSet); pascal CMError MyCMConcatenateProfiles ( ComponentInstance CMSession, CMProfileHandle thru, CMProfileHandle dst, CMProfileHandle *newDst); pascal CMError MyCMMGetPS2ColorSpace ( ComponentInstance CMSession, CMProfileRef srcProf, unsigned long flags, CMFlattenUPP proc, void *refCon); pascal CMError MyCMMGetPS2ColorRenderingIntent ( ComponentInstance CMSession, CMProfileRef srcProf, unsigned long flags, CMFlattenUPP proc, void *refCon); pascal CMError MyCMMGetPS2ColorRendering ( ComponentInstance CMSession, CMProfileRef srcProf, CMProfileRef dstProf, unsigned long flags, CMFlattenUPP proc, void *refCon); pascal CMError MyCMMGetPS2ColorRenderingVMSize ( ComponentInstance CMSession, CMProfileRef srcProf, CMProfileRef dstProf, unsigned long vmSize); pascal CMError MyCMMFlattenProfile ( ComponentInstance CMSession, CMProfileRef prof, unsigned long flags, CMFlattenUPP proc, void *refCon); pascal CMError MyCMMUnflattenProfile ( ComponentInstance CMSession, FSSpec *resultFileSpec, CMFlattenUPP proc, void *refCon); pascal CMError MyCMMGetNamedColorInfo( ComponentInstance CMSession, CMProfileRef srcProf, unsigned long *deviceChannels, OSType *deviceColorSpace, OSType *PCSColorSpace, unsigned long *count, StringPtr prefix, StringPtr suffix); pascal CMError MyCMMGetNamedColorValue( ComponentInstance CMSession, CMProfileRef prof, StringPtr name, CMColor *deviceColor, CMColor *PCSColor); pascal CMError MyCMMGetIndNamedColorValue( ComponentInstance CMSession, CMProfileRef prof, unsigned long index, CMColor *deviceColor, CMColor *PCSColor); pascal CMError MyCMMGetNamedColorIndex( ComponentInstance CMSession, CMProfileRef prof, StringPtr name, unsigned long *index); pascal CMError MyCMMGetNamedColorName( ComponentInstance CMSession, CMProfileRef prof, unsigned long index, StringPtr name);