Struct CieLchuv
Represents the CIE LCh°, cylindrical form of the CIE Luv* 1976 color. https://en.wikipedia.org/wiki/CIELAB_color_space#Cylindrical_representation:_CIELCh_or_CIEHLC
Implements
Inherited Members
Namespace: SixLabors.ImageSharp.ColorSpaces
Assembly: SixLabors.ImageSharp.dll
Syntax
public readonly struct CieLchuv : IEquatable<CieLchuv>
Constructors
| Improve this Doc View SourceCieLchuv(Vector3)
Initializes a new instance of the CieLchuv struct.
Declaration
public CieLchuv(Vector3 vector)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | vector | The vector representing the l, c, h components. |
Remarks
Uses DefaultWhitePoint as white point.
CieLchuv(Vector3, CieXyz)
Initializes a new instance of the CieLchuv struct.
Declaration
public CieLchuv(Vector3 vector, CieXyz whitePoint)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | vector | The vector representing the l, c, h components. |
CieXyz | whitePoint | The reference white point. Illuminants |
CieLchuv(Single, Single, Single)
Initializes a new instance of the CieLchuv struct.
Declaration
public CieLchuv(float l, float c, float h)
Parameters
Type | Name | Description |
---|---|---|
Single | l | The lightness dimension. |
Single | c | The chroma, relative saturation. |
Single | h | The hue in degrees. |
Remarks
Uses DefaultWhitePoint as white point.
CieLchuv(Single, Single, Single, CieXyz)
Initializes a new instance of the CieLchuv struct.
Declaration
public CieLchuv(float l, float c, float h, CieXyz whitePoint)
Parameters
Type | Name | Description |
---|---|---|
Single | l | The lightness dimension. |
Single | c | The chroma, relative saturation. |
Single | h | The hue in degrees. |
CieXyz | whitePoint | The reference white point. Illuminants |
Fields
| Improve this Doc View SourceC
Gets the a chroma component.
Declaration
public readonly float C
Field Value
Type | Description |
---|---|
Single |
DefaultWhitePoint
D50 standard illuminant. Used when reference white is not specified explicitly.
Declaration
public static readonly CieXyz DefaultWhitePoint
Field Value
Type | Description |
---|---|
CieXyz |
H
Gets the h° hue component in degrees.
Declaration
public readonly float H
Field Value
Type | Description |
---|---|
Single |
L
Gets the lightness dimension.
Declaration
public readonly float L
Field Value
Type | Description |
---|---|
Single |
WhitePoint
Gets the reference white point of this color
Declaration
public readonly CieXyz WhitePoint
Field Value
Type | Description |
---|---|
CieXyz |
Methods
| Improve this Doc View SourceEquals(CieLchuv)
Declaration
public readonly bool Equals(CieLchuv other)
Parameters
Type | Name | Description |
---|---|---|
CieLchuv | other |
Returns
Type | Description |
---|---|
Boolean |
Equals(Object)
Declaration
public override readonly bool Equals(object obj)
Parameters
Type | Name | Description |
---|---|---|
Object | obj |
Returns
Type | Description |
---|---|
Boolean |
Overrides
| Improve this Doc View SourceGetHashCode()
Declaration
public override readonly int GetHashCode()
Returns
Type | Description |
---|---|
Int32 |
Overrides
| Improve this Doc View SourceSaturation()
Computes the saturation of the color (chroma normalized by lightness)
Declaration
public readonly float Saturation()
Returns
Type | Description |
---|---|
Single | The Single |
Remarks
A value ranging from 0 to 100.
ToString()
Declaration
public override readonly string ToString()
Returns
Type | Description |
---|---|
String |
Overrides
Operators
| Improve this Doc View SourceEquality(CieLchuv, CieLchuv)
Compares two CieLchuv objects for equality.
Declaration
public static bool operator ==(CieLchuv left, CieLchuv right)
Parameters
Type | Name | Description |
---|---|---|
CieLchuv | left | The CieLchuv on the left side of the operand. |
CieLchuv | right | The CieLchuv on the right side of the operand. |
Returns
Type | Description |
---|---|
Boolean | True if the current left is equal to the |
Inequality(CieLchuv, CieLchuv)
Compares two CieLchuv objects for inequality
Declaration
public static bool operator !=(CieLchuv left, CieLchuv right)
Parameters
Type | Name | Description |
---|---|---|
CieLchuv | left | The CieLchuv on the left side of the operand. |
CieLchuv | right | The CieLchuv on the right side of the operand. |
Returns
Type | Description |
---|---|
Boolean | True if the current left is unequal to the |