You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7-5Lines changed: 7 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ Naming things is one of the hard things in computer science.
10
10
11
11
Colornamer-rs is a library written in Rust that helps you come up with a good name for a color.
12
12
13
-
It does this by converting the color to RGB colorspace and then finding the nearest neighbor in a list of colors.
13
+
It does this by converting the color to [Lab color space](https://en.wikipedia.org/wiki/Lab_color_space)and using the Delta E formula to compare the color difference in a list of colors with known names and finding the nearest neighbor.
14
14
15
15
## Example
16
16
@@ -38,14 +38,16 @@ The color names are derived from several lists:
38
38
* Pantone
39
39
* ntc - an [astounding collection](http://chir.ag/projects/ntc/) of over 1500 named colors.
40
40
41
-
## TODO
42
-
43
-
* Use [Lab color space](https://en.wikipedia.org/wiki/Lab_color_space) instead of RGB.
44
-
45
41
## Acknowledgements
46
42
47
43
This library is based on the wonderful [color-namer](https://github.com/colorjs/color-namer) library for nodejs.
48
44
45
+
Color difference formulas were found at [easyrgb.com](http://www.easyrgb.com/en/math.php).
46
+
47
+
Further reading:
48
+
49
+
*[Wikipedia article for color distance](https://en.wikipedia.org/wiki/Color_difference).
0 commit comments