CMSetProfileElement
Sets or replaces the element data for a specific tag in the specified profile.
Declaration
CMError CMSetProfileElement (
CMProfileRef prof,
OSType tag,
UInt32 elementSize,
const void *elementData
);Parameters
- prof:
A profile reference of type Cmprofileref to the profile containing the tag for which the element data is set.
- tag:
The tag signature for the element whose data is set. For a complete list of the tag signatures a profile may contain, including a description of each tag, refer to the International Color Consortium Profile Format Specification. The signatures for profile tags are defined in the
CMICCProfile.hheader file. - elementSize:
The size in bytes of the element data set.
- elementData:
A pointer to the buffer containing the element data to transfer to the profile.
Return Value
A CMError value. See Result Codes.
Overview
The CMSetProfileElement function replaces existing element data if an element with the specified tag is already present in the profile. Otherwise, it sets the element data for a new tag. Your application is responsible for allocating memory for the buffer to hold the data to transfer.