colors

extract colors from pictures
git clone git://git.2f30.org/colors
Log | Files | Refs | README | LICENSE

commit 4f006c77769ed7a7c2a2a771192ca1a1e44abe90
parent 5514163a781f9e8ff3d4239021cde16b5abc63ac
Author: z3bra <willy@mailoo.org>
Date:   Wed, 10 Jun 2015 16:06:14 +0200

Made distance value more readable in hex2col.c

Diffstat:
Mbin/hex2col.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/bin/hex2col.c b/bin/hex2col.c @@ -50,7 +50,7 @@ int quantization(int rgb[3]) { int i, tmp, index; - int distance = 195364; /* maximum distance between two colors */ + int distance = 442*442; /* it's always 442 somewhere */ for (i=0, tmp=0; i<256; i++) { tmp = (rgb[0] - map[i][0]) * (rgb[0] - map[i][0]) +