csharp
public readonly record struct OkLchA colour as perceptual lightness, chroma and hue.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
⚠ The conversion goes through linear RGB, because Oklab's input is linear and feeding it sRGB-encoded values produces something that is not Oklab and has none of the properties it is being used for. Vixen.Core.Mathematics says the same thing about the same function; it is repeated here because a colour picker is exactly where somebody reaches for the encoded value, which is the one they can see.
Fields and properties (4)
public float LLightness, 0 at black and about 1 at white.
public float CHow far from grey. Roughly 0 to 0.4 for anything inside sRGB.
public float HHue in degrees.
public bool IsInGamutWhether a monitor can actually make this colour.
Methods (3)
Used by (4)
- ColorFieldVixen.Ui.Controls.Advanced
- ColorModelTestsVixen.Ui.Controls.Advanced.Tests
- ColorPickerVixen.Ui.Controls.Advanced
- ColorPickerTestsVixen.Ui.Controls.Advanced.Tests