How to measure whether two colours match: CIELAB and ΔE in thread matching
When a photo becomes a chart, every colour needs a thread. A thread range has hundreds of shades, and choosing by eye takes ages. A computer works out which thread is closer. But what does "closer" mean for a colour? Here it is without formulas.
Why RGB numbers won't do
On screen, a colour is written as three numbers — red, green, blue (RGB). It seems you could just compare the numbers: the smaller the difference, the closer the colours. But the eye works differently. The same difference in RGB numbers is barely visible in dark blues and jumps out in yellow-greens. So matching by RGB goes wrong exactly where the mistake shows.
CIELAB — a space "as the eye sees"
To compare colours fairly, they're converted into the CIELAB space. It also has three numbers:
- L — lightness, from black to white;
- a — an axis from green to red;
- b — an axis from blue to yellow.
The space is built so that the same distance in it feels roughly the same to the eye anywhere around the colour wheel.
ΔE — a number for "how different"
The distance between two colours in CIELAB is called ΔE ("delta E"). The smaller it is, the closer the colours.
- ΔE76 is the simplest version: the plain distance between two points. It's quick, but it errs in saturated colours.
- CIEDE2000 is a refined formula. It takes into account that the eye is more sensitive to a difference in hue than in saturation, and corrects the blues. It takes longer to compute, but the result is closer to what a person sees.
Hence a common trick: first pick candidates quickly with the simple formula, then compare only those with the precise one.
When one thread isn't enough
Sometimes the range simply has no thread close to the colour you need: this happens with saturated blues and violets. Then a blend helps — two threads of different colours in one needle. From a distance the eye mixes them into an in-between shade.
The calculation isn't the last word
Even a precise formula compares colours on a screen, while thread reflects light, and its colour depends on the lamp and the fabric. So look at the skeins in person before you buy — see "Screen colour vs thread colour". For the whole path from photo to chart, see "Chart from a photo".
Where the app comes in
This is how Chart from a photo in Crossette works:
- the photo's colours are converted to CIELAB;
- similar colours are grouped using the simple ΔE76;
- each group gets its DMC thread by CIEDE2000;
- the "Thread blends" setting can allow blends of two threads: "off", "a few" or "as needed".
It's all worked out right on the phone.
About the author
This article was written by the Crossette team. We're building Crossette, a cross stitch tracker for iPhone and iPad. It's in development; to join the beta, see the Beta page.