IDS peak ICV v1.4.0
Loading...
Searching...
No Matches
ColorCorrectionMatrix Class Referencesealed
Inheritance diagram for ColorCorrectionMatrix:

Public Member Functions

 ColorCorrectionMatrix (string name, float[,] data)
 Creates an instance of class ColorCorrectionMatrix.
 
 ColorCorrectionMatrix (float[,] data)
 Creates an instance of class ColorCorrectionMatrix with data .
 
 ColorCorrectionMatrix (float[] data)
 Creates an instance of class ColorCorrectionMatrix with data .
 
void Serialize (IArchive archive)
 Serializes the object's internal state into the provided archive.
 
void Deserialize (IArchive archive)
 Restores the object's state from the provided archive.
 
IEnumerator< T > GetEnumerator ()
 
override int GetHashCode ()
 Computes a hash code based on all elements in the matrix.
 
override string ToString ()
 Returns a string representation of the matrix.
 

Static Public Member Functions

static ColorCorrectionMatrix Diagonal (float value)
 Constructs a uniform diagonal matrix.
 
static ColorCorrectionMatrix Identity ()
 Constructs a uniform identity matrix.
 
static Matrix< T > Diagonal (uint size, T value)
 Creates a diagonal matrix with the given value on the diagonal.
 
static Matrix< T > Identity (uint size)
 Creates an identity matrix of given size.
 

Properties

static new IEqualityComparer< ColorCorrectionMatrix > Comparer = new MatrixEqualityComparer() [get]
 Gets a default equality comparer for comparing ColorCorrectionMatrix data values.
 
uint Rows [get]
 Number of rows in the matrix.
 
uint Columns [get]
 Number of columns in the matrix.
 
T this[uint row, uint col] [get, set]
 Gets or sets the element at the specified row and column.
 

Detailed Description

Color correction matrix.

A color correction matrix is a 3x3 transformation matrix used to adjust RGB color values. It is typically used to convert colors from a camera sensors native RGB space to a standard color space, or to perform color balancing and correction.

The color correction matrix is represented as a 3x3 float array:

┌ ┐
│ m_00 │ m_01 │ m_02 │
│ m_10 │ m_11 │ m_12 │
│ m_20 │ m_21 │ m_22 │
└ ┘
See also
Features.ColorCorrectionFeature

for more information.

Since
IDSImaging.Peak.ICV 1.3

Constructor & Destructor Documentation

◆ ColorCorrectionMatrix() [1/3]

ColorCorrectionMatrix ( string name,
float data[,] )
inline

Creates an instance of class ColorCorrectionMatrix.

Parameters
nameThe name of the color correction matrix, used for serialization.
dataThe initial data for the color correction matrix.

◆ ColorCorrectionMatrix() [2/3]

ColorCorrectionMatrix ( float data[,])
inline

Creates an instance of class ColorCorrectionMatrix with data .

Parameters
dataThe initial data for the color correction matrix.

◆ ColorCorrectionMatrix() [3/3]

ColorCorrectionMatrix ( float[] data)
inline

Creates an instance of class ColorCorrectionMatrix with data .

Parameters
dataThe initial data for the color correction matrix.

Member Function Documentation

◆ Deserialize()

void Deserialize ( IArchive archive)
inline

Restores the object's state from the provided archive.

This function reads and applies all necessary parameters from the given archive to reconstruct the internal state of the object. It ensures that the object is restored to a valid and consistent state.

Parameters
archiveThe source archive containing the serialized parameters.

Implements ISerializable.

◆ Diagonal() [1/2]

static ColorCorrectionMatrix Diagonal ( float value)
inlinestatic

Constructs a uniform diagonal matrix.

Parameters
valueThe scalar value to be placed along the diagonal.
Returns
A Types.ColorCorrectionMatrix with value on the diagonal and zeros elsewhere.

◆ Diagonal() [2/2]

static Matrix< T > Diagonal ( uint size,
T value )
inlinestaticinherited

Creates a diagonal matrix with the given value on the diagonal.

Since
IDSImaging.Peak.ICV 1.3

◆ GetEnumerator()

IEnumerator< T > GetEnumerator ( )
inlineinherited

◆ GetHashCode()

override int GetHashCode ( )
inlineinherited

Computes a hash code based on all elements in the matrix.

Since
IDSImaging.Peak.ICV 1.3

◆ Identity() [1/2]

static ColorCorrectionMatrix Identity ( )
inlinestatic

Constructs a uniform identity matrix.

Returns
A Types.ColorCorrectionMatrix with ones on the diagonal and zeros elsewhere.

◆ Identity() [2/2]

static Matrix< T > Identity ( uint size)
inlinestaticinherited

Creates an identity matrix of given size.

Since
IDSImaging.Peak.ICV 1.3

◆ Serialize()

void Serialize ( IArchive archive)
inline

Serializes the object's internal state into the provided archive.

This function populates the given archive with all parameters required to fully represent the current state of the object. It ensures that the object can be reconstructed or transmitted accurately by saving all relevant data members in a consistent and structured format.

Parameters
archiveThe target archive that will store the serialized parameters.

Implements ISerializable.

◆ ToString()

override string ToString ( )
inlineinherited

Returns a string representation of the matrix.

Since
IDSImaging.Peak.ICV 1.3

Property Documentation

◆ Columns

uint Columns
getinherited

Number of columns in the matrix.

Since
IDSImaging.Peak.ICV 1.3

◆ Comparer

new IEqualityComparer<ColorCorrectionMatrix> Comparer = new MatrixEqualityComparer()
staticget

Gets a default equality comparer for comparing ColorCorrectionMatrix data values.

Since
IDSImaging.Peak.ICV 1.3

◆ Rows

uint Rows
getinherited

Number of rows in the matrix.

Since
IDSImaging.Peak.ICV 1.3

◆ this[uint row, uint col]

T this[uint row, uint col]
getsetinherited

Gets or sets the element at the specified row and column.

Since
IDSImaging.Peak.ICV 1.3