berendeanicolae / ColorSpace

C++ library for working with different color spaces, converting between color spaces and comparing colors
MIT License
137 stars 17 forks source link
color colorspace compare-colors comparison conversion convert-colors

ColorSpace

Build status

C++ library for converting between color spaces and comparing colors.

Color Conversion

You can convert between any supported color spaces using the To template method:

ColorSpace::Lab lab(100, 0, 0);
ColorSpace::Cmy cmy;
lab.To<ColorSpace::Cmy>(&cmy);

Color Comparison

You can compare colors by using the Compare method of each comparison class:

ColorSpace::Lab a(100, 0, 0);
ColorSpace::Rgb b(255, 255, 255);
ColorSpace::Cie2000Comparison::Compare(&a, &b);

Currently Supported Color Spaces

Currently Supported Comparisons

License

ColorSpace is licenced under the MIT License, see LICENSE for more information.