hueblocks icon indicating copy to clipboard operation
hueblocks copied to clipboard

Switch color comparison space

Open SimonDMC opened this issue 2 years ago • 0 comments

Using the RGB space for color comparison is pretty inaccurate due to how we perceive colors, and it can also result in weird block pallette duplications:

white to black artefacts of RGB space

This pull request fixes that, using the L*a*b* color space for a more perceptually uniform color transition :)

For more information about comparing colors, check out this useful post I used to find this out :D

The actual code I ended up using comes courtesy of @ryancat who wrote the exact script needed for this

SimonDMC avatar Jun 11 '22 17:06 SimonDMC