←Select platform

IccTag Structure

Contains the tag's information.
public struct IccTag 
public value class IccTag : public System.ValueType  
class IccTag: 
using Leadtools; 
using Leadtools.ColorConversion; 
using Leadtools.Codecs; 
public string inputIccFile = Path.Combine(LEAD_VARS.ImagesDir, "IccProfileExtended.icc"); 
public string outputIccFile = Path.Combine(LEAD_VARS.ImagesDir, "IccProfileExtendedConstructor.icc"); 
public DateTime sysDateTime = DateTime.Now; // Get the current system data 
public void IccProfileExtendedConstructorExample() 
   // Load an ICC profile 
   IccProfileExtended iccProfile = new IccProfileExtended(inputIccFile); 
   // Create the new header 
   IccHeader header = IccHeader.Empty; 
   header.CmmID = 0x6170706C; // Any CMM ID 
   header.DeviceClass = IccProfileClassType.DeviceLinkClass; 
   header.ColorSpace = IccColorspaceType.LabData; 
   header.Pcs = IccColorspaceType.LabData; 
   header.ProfileSignature = 0x61637370; // Any profile signature 
   header.Platform = IccPlatformSignatureType.MacintoshSignature; 
   header.Flags = IccProfileFlags.None; 
   header.Manufacturer = 0x46464549; // Any manufacturer 
   header.Model = 0x0; // Any model 
   header.Attributes = IccProfileMediaFlags.ColorMedia; 
   header.RenderingIntent = IccRenderingIntentType.AbsoluteColorimetric; 
   header.Creator = 0x46464549; // Any creator 
   // Set the system date/time as the date/time of the ICC profile 
   IccDateTime iccDateTime = new IccDateTime((ushort)sysDateTime.Year, 
   header.DateTime = iccDateTime; 
   // Copy the tag list 
   int tagCount = iccProfile.TagList.Tags.Length; 
   IccTag[] tags = new IccTag[tagCount]; 
   for (int i = 0; i < tagCount; i++) 
      tags[i] = new IccTag(iccProfile.TagList.Tags[i].Signature, 
   IccTagList tagList = new IccTagList(tags); 
   // Copy the tag data 
   byte[] tagData = new byte[iccProfile.TagData.Length]; 
   iccProfile.TagData.CopyTo(tagData, 0); 
   // Create the new ICC profile, the Data array parameter will not be passed, because it will be updated when calling the UpdateDataArray() method. 
   IccProfileExtended newIccProfile = new IccProfileExtended(header, tagList, tagData, null); 
   // Generate the profileId. For the time being, it will be filled with 0's 
   // Finally generate the new ICC profile by updating the Data Array and then generating the file 
static class LEAD_VARS 
   public const string ImagesDir = @"C:\LEADTOOLS23\Resources\Images"; 

Target Platforms

Help Version 23.0.2024.2.29
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.ColorConversion Assembly

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.