XyztoLab

Color
stable

Convert a CIE XYZ (D65) colour to CIE L*a*b* by applying the CIELAB forward transform. Used to perform perceptually uniform lightness adjustments (lighten/darken).

API

Signature

Full TypeScript signature sourced from the util file.

typescript

API

Parameters

Input parameters accepted by this util.

xyz
required
TXYZ
CIE XYZ tristimulus tuple [X, Y, Z] normalised to the D65 illuminant.

API

Return value

The value returned by this util.

CIE L*a*b* triplet as a tuple [L, a, b]. L in [0, 100], a and b typically in [-128, 127].

Usage

Examples

Ready-to-paste usage snippets.

XYZ to Lab

typescript