Hacker News new | past | comments | ask | show | jobs | submit login
Chroma.js – A JavaScript library for color conversions and color scales (github.com)
66 points by hising on Nov 13, 2014 | hide | past | web | favorite | 6 comments

Awesome, I've been looking for something exactly like this

I've just implemented it to set the text colour on http://www.stevengapo.com (which gets its colour scheme from random instagram photos) and it's much more readable now

The blog posts from Chroma.js https://vis4.net/blog/posts/avoid-equidistant-hsv-colors/ https://vis4.net/blog/posts/mastering-multi-hued-color-scale... are really nice, and help you figure out how to use Chroma.js (and the LAB color scheme). Nice work!

And here's a blog post from a year ago on Chroma.js that goes into a bit of detail about why it matters and some demos: https://vis4.net/blog/posts/mastering-multi-hued-color-scale...

couple additional links/libs for human-friendly color models:



There's also PleaseJS: https://github.com/Fooidge/PleaseJS

shameless plug, if you need to do color reduction for images:

play: http://o-0.me/RgbQuant/

code: https://github.com/leeoniya/RgbQuant.js

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact