![]() |
CMGetDefaultProfileBySpace |
||||
Header: | CMApplication.h | Carbon status: | Supported | |
Gets the default profile for the specified color space.
CMError CMGetDefaultProfileBySpace ( OSType dataColorSpace, CMProfileRef *prof );
A four-character identifier of type OSType. You pass a color space signature that identifies the color space you wish to get the default profile for. The currently-supported values are cmRGBData, cmCMYKData, cmLabData, and cmXYZData. These constants are a subset of the constants described in
A pointer to a profile reference. On return, the reference specifies the current profile for the color space specified by dataColorSpace. CMGetDefaultProfileBySpace currently supports only file-based profiles.
The CMGetDefaultProfileBySpace function currently supports the RGB, CMYK, Lab, and XYZ color spaces. The signature constants for these color spaces (shown above with the dataColorSpace parameter description) are described in
The CMGetDefaultProfileBySpace function always attempts to return a file-based profile for a supported color space. For example, if the user has not specified a default profile in the ColorSync control panel for the specified color space, or if the profile is not found (the user may have deleted the profiles in the ColorSync Profiles folder or even the folder itself), CMGetDefaultProfileBySpace creates a profile, stores it on disk, and returns a reference to that profile. However, you should always check for an error returnfor example, a user may have booted from a CD, so that CMGetDefaultProfileBySpace cannot save a profile file to disk.
Supported in Carbon. Available in Carbon 1.0.2 and later when ColorSync 2.5 or later is present.
© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)