Graphics Mill for .NET allows using Adobe® Color Management Module (CMM) as well as LittleCMS engine. This article reviews the Adobe® CMM and shows how to use this module with Graphics Mill for .NET
The Adobe® CMM is the color conversion engine which allows transformation of colors using ICC (International Color Consortium) color profiles. This module is based on the Adobe Color Engine (ACE) and represented in a form which can be used by non-Adobe applications.
Adobe® CMM can be used with x86 version of Aurigma Graphics Mill 5.5 for .NET only.
Adobe® CMM requires Microsoft® Windows XP with Service Pack 2, Windows Vista, or Windows Server 2003.
Before developing an application that uses Adobe® CMM, this module must be installed on the development machine.
To install Adobe® CMM on the development machine, perform the following steps:
If the Adobe® CMM is successfully installed on your development machine, you can use it with Graphics Mill for .NET.
To specify a color management engine, Graphics Mill for .NET provides the ColorManagementProvider.ColorManagementEngine and PixelFormatConverter.ColorManagementEngine properties. You need to set these properties to AdobeCmm value to enable Adobe CMM for color matching operations. However if you set AdobeCmm value, it is not guaranteed that this module will be used during color conversion operations because it should be installed on the machine where application is launched. To check whether Adobe CMM is available in the system you can use GlobalSettings.IsAdobeCmmAccessible property.
The following code sample demonstrates how to check whether the Adobe® CMM is installed and use this module to convert pixels between CMYK and RGB.
Dim inputFile As String = "C:\Cmyk32.jpg" Dim outputFile As String = "C:\Rgb24.jpg" Dim bitmap As New Aurigma.GraphicsMill.Bitmap() If (Aurigma.GraphicsMill.GlobalSettings.IsAdobeCmmAccessible) Then bitmap.ColorManagement.ColorManagementEngine = Aurigma.GraphicsMill.Transforms.ColorManagementEngine.AdobeCmm Else bitmap.ColorManagement.ColorManagementEngine = Aurigma.GraphicsMill.Transforms.ColorManagementEngine.LittleCms End If bitmap.Load(inputFile) bitmap.ColorManagement.RgbColorProfile = Aurigma.GraphicsMill.ColorProfile.FromSrgb() bitmap.ColorManagement.ConvertToContinuous(Aurigma.GraphicsMill.ColorSpace.Rgb, False, bitmap.IsExtended) bitmap.Save(outputFile)
string inputFile = @"C:\Cmyk32.jpg"; string outputFile = @"C:\Rgb24.jpg"; Aurigma.GraphicsMill.Bitmap bitmap = new Aurigma.GraphicsMill.Bitmap(); if (Aurigma.GraphicsMill.GlobalSettings.IsAdobeCmmAccessible) bitmap.ColorManagement.ColorManagementEngine = Aurigma.GraphicsMill.Transforms.ColorManagementEngine.AdobeCmm; else bitmap.ColorManagement.ColorManagementEngine = Aurigma.GraphicsMill.Transforms.ColorManagementEngine.LittleCms; bitmap.Load(inputFile); bitmap.ColorManagement.RgbColorProfile = Aurigma.GraphicsMill.ColorProfile.FromSrgb(); bitmap.ColorManagement.ConvertToContinuous(Aurigma.GraphicsMill.ColorSpace.Rgb, false, bitmap.IsExtended); bitmap.Save(outputFile);
If the application is based on Graphics Mill for .NET and uses Adobe® CMM for color conversion operations, you should guarantee that Adobe® CMM is installed on users' systems. You need to tell about it in your documenation and consider to redistribute Adobe® CMM along with your installation package.