19 #ifndef __CMDEVICEINTEGRATION__
20 #define __CMDEVICEINTEGRATION__
26 #ifndef __CMAPPLICATION__
30 #ifndef __CMICCPROFILE__
51 #if PRAGMA_STRUCT_ALIGN
52 #pragma options align = mac68k
53 #elif PRAGMA_STRUCT_PACKPUSH
55 #elif PRAGMA_STRUCT_PACK
59 #if TARGET_API_MAC_OSX
66 cmDeviceInfoVersion1 = 0x00010000,
67 cmDeviceProfileInfoVersion1 = 0x00010000
72 cmCurrentDeviceInfoVersion = cmDeviceInfoVersion1,
73 cmCurrentProfileInfoVersion = cmDeviceProfileInfoVersion1
82 cmDefaultDeviceID = 0,
83 cmDefaultProfileID = 0
92 cmDeviceStateDefault = 0x00000000,
93 cmDeviceStateOffline = 0x00000001,
94 cmDeviceStateBusy = 0x00000002,
95 cmDeviceStateForceNotify = (long)0x80000000,
96 cmDeviceStateDeviceRsvdBits = 0x00FF0000,
97 cmDeviceStateAppleRsvdBits = (
long)0xFF00FFFF
127 cmIterateFactoryDeviceProfiles = 0x00000001,
128 cmIterateCustomDeviceProfiles = 0x00000002,
129 cmIterateCurrentDeviceProfiles = 0x00000003,
130 cmIterateDeviceProfilesMask = cmIterateCurrentDeviceProfiles
135 kMaxDeviceNameLength = 256,
136 kMaxProfileNameLength = 256
144 cmDeviceDBNotFoundErr = -4227,
145 cmDeviceAlreadyRegistered = -4228,
146 cmDeviceNotRegistered = -4229,
147 cmDeviceProfilesNotFound = -4230,
148 cmInternalCFErr = -4231
163 #define kCMDeviceRegisteredNotification CFSTR("CMDeviceRegisteredNotification")
164 #define kCMDeviceUnregisteredNotification \
165 CFSTR("CMDeviceUnregisteredNotification")
166 #define kCMDeviceOnlineNotification CFSTR("CMDeviceOnlineNotification")
167 #define kCMDeviceOfflineNotification CFSTR("CMDeviceOfflineNotification")
168 #define kCMDeviceStateNotification CFSTR("CMDeviceStateNotification")
169 #define kCMDefaultDeviceNotification CFSTR("CMDefaultDeviceNotification")
170 #define kCMDeviceProfilesNotification CFSTR("CMDeviceProfilesNotification")
171 #define kCMDefaultDeviceProfileNotification \
172 CFSTR("CMDefaultDeviceProfileNotification")
177 typedef UInt32 CMDeviceState;
181 typedef UInt32 CMDeviceID;
185 typedef UInt32 CMDeviceProfileID;
191 cmScannerDeviceClass = FOUR_CHAR_CODE(
'scnr'),
192 cmCameraDeviceClass = FOUR_CHAR_CODE(
'cmra'),
193 cmDisplayDeviceClass = FOUR_CHAR_CODE(
'mntr'),
194 cmPrinterDeviceClass = FOUR_CHAR_CODE(
'prtr'),
195 cmProofDeviceClass = FOUR_CHAR_CODE(
'pruf')
198 typedef OSType CMDeviceClass;
205 CFStringRef deviceUser;
206 CFStringRef deviceHost;
208 typedef struct CMDeviceScope CMDeviceScope;
216 CMDeviceClass deviceClass;
218 CMDeviceScope deviceScope;
219 CMDeviceState deviceState;
220 CMDeviceProfileID defaultProfileID;
221 CFDictionaryRef *deviceName;
226 typedef struct CMDeviceInfo CMDeviceInfo;
227 typedef CMDeviceInfo *CMDeviceInfoPtr;
232 struct CMDeviceProfileInfo
235 CMDeviceProfileID profileID;
237 CFDictionaryRef profileName;
240 typedef struct CMDeviceProfileInfo CMDeviceProfileInfo;
245 struct CMDeviceProfileArray
248 CMDeviceProfileInfo profiles[1];
250 typedef struct CMDeviceProfileArray CMDeviceProfileArray;
251 typedef CMDeviceProfileArray *CMDeviceProfileArrayPtr;
255 typedef CALLBACK_API_C(OSErr, CMIterateDeviceInfoProcPtr)(
256 const CMDeviceInfo *deviceInfo,
void *refCon);
257 typedef CALLBACK_API_C(OSErr, CMIterateDeviceProfileProcPtr)(
258 const CMDeviceInfo *deviceInfo,
const CMDeviceProfileInfo *profileData,
272 CMRegisterColorDevice(CMDeviceClass deviceClass, CMDeviceID deviceID,
273 CFDictionaryRef deviceName,
274 const CMDeviceScope *deviceScope);
285 CMUnregisterColorDevice(CMDeviceClass deviceClass, CMDeviceID deviceID);
299 CMSetDefaultDevice(CMDeviceClass deviceClass, CMDeviceID deviceID);
310 CMGetDefaultDevice(CMDeviceClass deviceClass, CMDeviceID *deviceID);
324 CMSetDeviceFactoryProfiles(CMDeviceClass deviceClass, CMDeviceID deviceID,
325 CMDeviceProfileID defaultProfID,
326 const CMDeviceProfileArray *deviceProfiles);
337 CMGetDeviceFactoryProfiles(CMDeviceClass deviceClass, CMDeviceID deviceID,
338 CMDeviceProfileID *defaultProfID, UInt32 *arraySize,
339 CMDeviceProfileArray *deviceProfiles);
350 CMSetDeviceProfiles(CMDeviceClass deviceClass, CMDeviceID deviceID,
351 const CMDeviceScope *profileScope,
352 const CMDeviceProfileArray *deviceProfiles);
363 CMGetDeviceProfiles(CMDeviceClass deviceClass, CMDeviceID deviceID,
364 UInt32 *arraySize, CMDeviceProfileArray *deviceProfiles);
375 CMSetDeviceDefaultProfileID(CMDeviceClass deviceClass, CMDeviceID deviceID,
376 CMDeviceProfileID defaultProfID);
387 CMGetDeviceDefaultProfileID(CMDeviceClass deviceClass, CMDeviceID deviceID,
388 CMDeviceProfileID *defaultProfID);
399 CMGetDeviceProfile(CMDeviceClass deviceClass, CMDeviceID deviceID,
400 CMDeviceProfileID profileID,
412 CMSetDeviceProfile(CMDeviceClass deviceClass, CMDeviceID deviceID,
413 const CMDeviceScope *profileScope,
414 CMDeviceProfileID profileID,
429 CMSetDeviceState(CMDeviceClass deviceClass, CMDeviceID deviceID,
430 CMDeviceState deviceState);
441 CMGetDeviceState(CMDeviceClass deviceClass, CMDeviceID deviceID,
442 CMDeviceState *deviceState);
453 CMGetDeviceInfo(CMDeviceClass deviceClass, CMDeviceID deviceID,
454 CMDeviceInfo *deviceInfo);
468 CMIterateColorDevices(CMIterateDeviceInfoProcPtr proc, UInt32 *seed,
469 UInt32 *count,
void *refCon);
480 CMIterateDeviceProfiles(CMIterateDeviceProfileProcPtr proc, UInt32 *seed,
481 UInt32 *count, UInt32 flags,
void *refCon);
485 #if PRAGMA_STRUCT_ALIGN
486 #pragma options align = reset
487 #elif PRAGMA_STRUCT_PACKPUSH
489 #elif PRAGMA_STRUCT_PACK
493 #ifdef PRAGMA_IMPORT_OFF
Color Matching Interfaces.
ICC Profile Format Definitions.
Basic Macintosh data types.
Definition: CMApplication.h:636