Struct CieLab
Represents a CIE Lab* 1976 color. https://en.wikipedia.org/wiki/Lab_color_space
Implements
Inherited Members
Namespace: SixLabors.ImageSharp.ColorSpaces
Assembly: SixLabors.ImageSharp.dll
Syntax
public readonly struct CieLab : IEquatable<CieLab>Constructors
| Improve this Doc View SourceCieLab(Vector3)
Initializes a new instance of the CieLab struct.
Declaration
public CieLab(Vector3 vector)Parameters
| Type | Name | Description | 
|---|---|---|
| Vector3 | vector | The vector representing the l, a, b components. | 
Remarks
Uses DefaultWhitePoint as white point.
CieLab(Vector3, CieXyz)
Initializes a new instance of the CieLab struct.
Declaration
public CieLab(Vector3 vector, CieXyz whitePoint)Parameters
| Type | Name | Description | 
|---|---|---|
| Vector3 | vector | The vector representing the l, a, b components. | 
| CieXyz | whitePoint | The reference white point. Illuminants | 
CieLab(Single, Single, Single)
Initializes a new instance of the CieLab struct.
Declaration
public CieLab(float l, float a, float b)Parameters
| Type | Name | Description | 
|---|---|---|
| Single | l | The lightness dimension. | 
| Single | a | The a (green - magenta) component. | 
| Single | b | The b (blue - yellow) component. | 
Remarks
Uses DefaultWhitePoint as white point.
CieLab(Single, Single, Single, CieXyz)
Initializes a new instance of the CieLab struct.
Declaration
public CieLab(float l, float a, float b, CieXyz whitePoint)Parameters
| Type | Name | Description | 
|---|---|---|
| Single | l | The lightness dimension. | 
| Single | a | The a (green - magenta) component. | 
| Single | b | The b (blue - yellow) component. | 
| CieXyz | whitePoint | The reference white point. Illuminants | 
Fields
| Improve this Doc View SourceA
Gets the a color component.
Declaration
public readonly float AField Value
| Type | Description | 
|---|---|
| Single | 
B
Gets the b color component.
Declaration
public readonly float BField Value
| Type | Description | 
|---|---|
| Single | 
DefaultWhitePoint
D50 standard illuminant. Used when reference white is not specified explicitly.
Declaration
public static readonly CieXyz DefaultWhitePointField Value
| Type | Description | 
|---|---|
| CieXyz | 
L
Gets the lightness dimension.
Declaration
public readonly float LField Value
| Type | Description | 
|---|---|
| Single | 
WhitePoint
Gets the reference white point of this color
Declaration
public readonly CieXyz WhitePointField Value
| Type | Description | 
|---|---|
| CieXyz | 
Methods
| Improve this Doc View SourceEquals(CieLab)
Declaration
public readonly bool Equals(CieLab other)Parameters
| Type | Name | Description | 
|---|---|---|
| CieLab | 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 SourceToString()
Declaration
public override readonly string ToString()Returns
| Type | Description | 
|---|---|
| String | 
Overrides
Operators
| Improve this Doc View SourceEquality(CieLab, CieLab)
Compares two CieLab objects for equality.
Declaration
public static bool operator ==(CieLab left, CieLab right)Parameters
| Type | Name | Description | 
|---|---|---|
| CieLab | left | The CieLab on the left side of the operand. | 
| CieLab | right | The CieLab on the right side of the operand. | 
Returns
| Type | Description | 
|---|---|
| Boolean | True if the current left is equal to the  | 
Inequality(CieLab, CieLab)
Compares two CieLab objects for inequality
Declaration
public static bool operator !=(CieLab left, CieLab right)Parameters
| Type | Name | Description | 
|---|---|---|
| CieLab | left | The CieLab on the left side of the operand. | 
| CieLab | right | The CieLab on the right side of the operand. | 
Returns
| Type | Description | 
|---|---|
| Boolean | True if the current left is unequal to the  |