Table of Contents

Struct Lms

Namespace
SixLabors.ImageSharp.ColorSpaces
Assembly
SixLabors.ImageSharp.dll

LMS is a color space represented by the response of the three types of cones of the human eye, named after their responsivity (sensitivity) at long, medium and short wavelengths. https://en.wikipedia.org/wiki/LMS_color_space

public readonly struct Lms : IEquatable<Lms>
Implements
Inherited Members

Constructors

Lms(Vector3)

Initializes a new instance of the Lms struct.

public Lms(Vector3 vector)

Parameters

vector Vector3

The vector representing the l, m, s components.

Lms(float, float, float)

Initializes a new instance of the Lms struct.

public Lms(float l, float m, float s)

Parameters

l float

L represents the responsivity at long wavelengths.

m float

M represents the responsivity at medium wavelengths.

s float

S represents the responsivity at short wavelengths.

Properties

L

Gets the L long component. A value usually ranging between -1 and 1.

public float L { get; }

Property Value

float

M

Gets the M medium component. A value usually ranging between -1 and 1.

public float M { get; }

Property Value

float

S

Gets the S short component. A value usually ranging between -1 and 1.

public float S { get; }

Property Value

float

Methods

Equals(Lms)

public bool Equals(Lms other)

Parameters

other Lms

Returns

bool

Equals(object?)

public override bool Equals(object? obj)

Parameters

obj object

Returns

bool

GetHashCode()

public override int GetHashCode()

Returns

int

ToString()

public override string ToString()

Returns

string

ToVector3()

Returns a new Vector3 representing this instance.

public Vector3 ToVector3()

Returns

Vector3

The Vector3.

Operators

operator ==(Lms, Lms)

Compares two Lms objects for equality.

public static bool operator ==(Lms left, Lms right)

Parameters

left Lms

The Lms on the left side of the operand.

right Lms

The Lms on the right side of the operand.

Returns

bool

True if the current left is equal to the right parameter; otherwise, false.

operator !=(Lms, Lms)

Compares two Lms objects for inequality.

public static bool operator !=(Lms left, Lms right)

Parameters

left Lms

The Lms on the left side of the operand.

right Lms

The Lms on the right side of the operand.

Returns

bool

True if the current left is unequal to the right parameter; otherwise, false.