Advance apology for mobile users: there is no buffering for this demo. Please bookmark it and return when you're on desktop if you'd like to see the fun. (Sorry!)
If color difference interests you at all, I highly recommend reading the Learn page. It's a fun read:
In all, I'd estimate I spent 100 hours in learning about color difference, creating this library, and ultimately creating this demo. It was a fun ride with many stories in itself.
This library is released as public domain. Go nuts. If you create anything cool (or boring and useful) let me know - I'll link to your project.
This is my first post to HN, but I'm very receptive to constructive feedback or questions. Fire away! :-)
A little trick you can use here is squared distance which avoids the relatively expensive square root (also do the square in-place rather than pow) so your distance function becomes:
(d - a) * (d - a) + (e - b) * (e - b) + (f - c) * (f - c)
You will need to also square your threshold values.
Great work implementing this - just the fact that I now know that his kind of realtime image processing is possible in the browser certainly provides lots of fuel for project ideas. Summer hasn't even started but it already got better. Thanks a ton!
6 comments
[ 4.1 ms ] story [ 25.4 ms ] threadThe Sharma et al. paper is worth reading for some of the implementation/stability pitfalls: http://www.ece.rochester.edu/~gsharma/ciede2000/
I believe I spent a couple days of agonizing troubleshooting to find the bug. Lots of places for it to hide in that wall of math...
Thanks for sharing!
Advance apology for mobile users: there is no buffering for this demo. Please bookmark it and return when you're on desktop if you'd like to see the fun. (Sorry!)
If color difference interests you at all, I highly recommend reading the Learn page. It's a fun read:
http://zschuessler.github.io/DeltaE/learn/
In all, I'd estimate I spent 100 hours in learning about color difference, creating this library, and ultimately creating this demo. It was a fun ride with many stories in itself.
This library is released as public domain. Go nuts. If you create anything cool (or boring and useful) let me know - I'll link to your project.
This is my first post to HN, but I'm very receptive to constructive feedback or questions. Fire away! :-)
A little trick you can use here is squared distance which avoids the relatively expensive square root (also do the square in-place rather than pow) so your distance function becomes:
(d - a) * (d - a) + (e - b) * (e - b) + (f - c) * (f - c)
You will need to also square your threshold values.