# qualpal::metrics

C++ · 4.1.0

[Source](<https://github.com/jolars/qualpal/blob/887b793a3795d298a62e49356a72314ce59dab0d/include/qualpal/metrics.h>)

```cpp
namespace qualpal::metrics
```

Color difference metrics for perceptual color comparison. 

Contains functor classes implementing standard color difference formulas ([DIN99d](<27015d2beab2e4039b5bacc5eabfad002f7b2746b0445119676aada1f32a432d>), [CIE76](<9898a856a6f81d8ca2916b360ef9cb6ae98bbea3456e714e4c7391fdff024b9e>), [CIEDE2000](<5333d0fe7760f4247a9ab5c591dde9118c40d0893b9c057884147334a8038ebd>)) for quantifying perceptual differences between colors. Used in palette selection (e.g., farthestPoints()), palette analysis, and color distinguishability evaluation.

All metric classes:

- Are callable with operator() taking two color objects.
- Are template-based to accept any color type convertible to the required color space.
- Return a numeric difference value (Delta E; higher = more different).

<a id="documentation-see-also"></a>

### See also

[colorDifferenceMatrix()](<9d25e7ba64ee1080c23302f787ad211e930ad168abad0dd2433baff2228dffe6#cpp-cb588a6f7fd35071934e2ef49e83dcf59ba428ad9f98021b08df43921008ab9b>) for computing full distance matrices. 

 

<a id="documentation-see-also-2"></a>

### See also

farthestPoints() for palette selection using these [metrics](<288899333fe9e772153ad16626d5ae4275c5aaa60c646e97970a4e37ba81ab26>).
