Class IccProfile
- Namespace
- SixLabors.ImageSharp.Metadata.Profiles.Icc
- Assembly
- SixLabors.ImageSharp.dll
Represents an ICC profile
public sealed class IccProfile : IDeepCloneable<IccProfile>
- Inheritance
-
IccProfile
- Implements
- Inherited Members
Constructors
IccProfile()
Initializes a new instance of the IccProfile class.
public IccProfile()
IccProfile(byte[])
Initializes a new instance of the IccProfile class.
public IccProfile(byte[] data)
Parameters
data
byte[]The raw ICC profile data
Properties
Entries
Gets the actual profile data
public IccTagDataEntry[] Entries { get; }
Property Value
Header
Gets or sets the profile header
public IccProfileHeader Header { get; set; }
Property Value
Methods
CalculateHash(byte[])
Calculates the MD5 hash value of an ICC profile
public static IccProfileId CalculateHash(byte[] data)
Parameters
data
byte[]The data of which to calculate the hash value
Returns
- IccProfileId
The calculated hash
CheckIsValid()
Checks for signs of a corrupt profile.
public bool CheckIsValid()
Returns
- bool
True if the profile is valid; False otherwise
Remarks
This is not an absolute proof of validity but should weed out most corrupt data.
DeepClone()
public IccProfile DeepClone()
Returns
ToByteArray()
Converts this instance to a byte array.
public byte[] ToByteArray()
Returns
- byte[]
The byte[]