{ lightness : Basics.Float
, a : Basics.Float
, b : Basics.Float
, alpha : Basics.Float
}
A color in the Oklab space.
lightness
ranges from 0.0 to 1.0 (inclusive),a
(green/red) ranges from approximatively -0.3 to +0.3,b
(blue/yellow) ranges from approximatively -0.3 to +0.3,alpha
ranges from 0.0 to 1.0 (inclusive).oklab : Basics.Float -> Basics.Float -> Basics.Float -> Oklab
Builds a color from its lightness, a (green/red) and b (blue/yellow) components.
lightness
ranges from 0.0 to 1.0 (inclusive),a
(green/red) ranges from approximatively -0.3 to +0.3,b
(blue/yellow) ranges from approximatively -0.3 to +0.3.oklaba : Basics.Float -> Basics.Float -> Basics.Float -> Basics.Float -> Oklab
Builds a color from its lightness, a (green/red), b (blue/yellow) and alpha components.
lightness
ranges from 0.0 to 1.0 (inclusive),a
(green/red) ranges from approximatively -0.3 to +0.3,b
(blue/yellow) ranges from approximatively -0.3 to +0.3,alpha
ranges from 0.0 to 1.0 (inclusive).fromColor : Color -> Oklab
Convert a color from Color
(sRGB) to Oklab.
toColor : Oklab -> Color
Convert a color from Oklab to Color
(sRGB).
fromLinearRGB : Color.LinearRGB.LinearRGB -> Oklab
Converts a color from linear RGB (red, green, blue) to Oklab.
The components should be between 0.0 and 1.0 (inclusive).
toLinearRGB : Oklab -> Color.LinearRGB.LinearRGB
Converts a color from Oklab to linear RGB (red, green, blue).
The output components get clipped at 0 to avoid NaNs.