The ICC Profile format is defined by the International Color Consortium (ICC). For background on the origination and purpose of this format, refer to http://www.color.org/index.xalter.
Creating an ICC Profile
To create an ICC profile, start by create a new IccProfileExtended object. Within the IccProfileExtended class is an IccHeader structure that contains header information for the profile. Once the IccProfileExtended object has been initialized, it will contain an empty header but it can be initialized by calling the IccHeader constructor. It is also possible to define a new IccHeader structure and use the IccHeader.Empty property to sets the members of the IccHeader structure to their default values.
Tags
The ICC Profile can use tags. Tags can be inserted in an ICC profile, created but not inserted, or deleted. To insert a tag in an ICC profile, perform the following steps:
Define a structure of the same "type" as the tag to be created.
Fill the structure with the required data.
Define an object of the same "type" and use the structure to Initializes this object.
Call the IccProfileExtended.AddTag method to insert the tag into the ICC profile.
To create a tag without inserting it into an ICC profile, call the IccTools.CreateTagType method.
At any time you can get a tag from an ICC profile by calling the IccProfileExtended.GetTagmethod. Delete a tag by calling the IccProfileExtended.DeleteTag method.
Tags are of various types. These types have a signature associated with them to identify them. Tags also have signatures associated with them. One or both of these signatures may be used when creating, inserting or deleting tags. To get the signature of a specific tag type, call the IccProfileExtended.GetTagTypeSignature method. For more information on tags, types and signatures, please refer to the documentation available through http://www.color.org/index.xalter.
When working with ICC profiles, it may be necessary to convert values from one form to another. Variables of the type IccS15Fixed16ArrayTagType, or IccU16Fixed16ArrayTagType require data in a 2 bytes fixed, 2 bytes number form. The IccTools.FromDoubleTo2bFixed2bNumber method converts a double value into a 2 bytes fixed, 2 bytes number form, allowing the user to set these variables. The IccTools.From2bFixed2bNumberToDouble method converts a 2 bytes fixed, 2 bytes number value into a double value, allowing the user to get data from these variables.
Similarly, the type IccUint8ArrayTagType requires data in a 1 byte fixed, 1 byte number form. The IccTools.FromDoubleToU8Fixed8Number method converts a double value into a 1 byte fixed, 1 byte number form. The IccTools.FromU8Fixed8NumberToDouble method converts a 1 byte fixed, 1 byte number value into a double value.
The TagData structure will always contain the correct values, regardless of whether a new ICC profile is being created or an existing one is being modified. The Data array will not contain any values until a call to the IccProfileExtended.UpdateDataArray method is made. This method updates the Data array with the latest modifications. Please note however, that before calling any of the IccProfileExtended.GenerateIccFile or IccProfileExtended.WriteToImagemethods, make sure that the Size and Data members of the IccProfileExtended structure has the right data either by loading an ICC profile into them, or by calling the IccProfileExtended.UpdateDataArray method to generate them.
Loading an ICC Profile
ICC profiles can be saved to ICC files or embedded in image files and loaded at a later date. Before loading an existing ICC profile from a saved file. To load an ICC profile from an image file, call the IccProfileExtended.ReadFromImage method. . When using this method of loading a ICC profile into this structure, the data member will contain all the profile data in one block of memory, and the TagData array will contain only the tag's data in one block of memory.
Saving an ICC Profile An ICC profile can be saved (or embedded), in a TIFF, GIF or JPEG image file by calling the IccProfileExtended.WriteToImage method. To save an ICC profile to an ICC profile file, call the IccProfileExtended.GenerateIccFile method.
Products |
Support |
Feedback: Using ICC Profile Functions |
Introduction |
Help Version 19.0.2017.6.21
|
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.