3 ms·
I got deep into color contrast algorithms. Human vision is a rabbit hole indeed. You would think that this is a well established field. But then I found claims
by ximm 4y ago
I got deep into color contrast algorithms. Human vision is a rabbit hole indeed.
You would think that this is a well established field. But then I found claims in online discussions (including at the W3C) that were obviously wrong on a mathematical level. The more I looked, the more the arguments fell apart. So instead of reading online discussions I concentrated on reading the actual formulas as well as research on the topic. I now belive that the reasons people cite for choosing one algorithm over another are often completely bogus.
I tried to bring this up at the W3C, but the response was anything but friendly. Not sure what I did wrong. I still think that I have something valuable to contribute, but I am not sure how.
If you are interested in more details: http://tobib.spline.de/xi/posts/2022-09-10-contrast-algorithms/ http://tobib.spline.de/xi/posts/2022-09-10-contrast-algorith...
- e-_pusher 4y agoGreat write up. Color overall is a rabbit hole of a topic. I have been looking into color matching, delta E etc. and it is been surprise to realize that the variances of human vision mean that the field of colorimetry is as much of an art as it is science.
- feoren 4y agoYour blog post makes lots of sense if all you care about is one threshold: contrast must be above X for readability. Then the equivalence-under-monotonic-function makes total sense: you literally don't care what the function does above or below your threshold. This extends to if you pick N threshold points (text must be above Contrast1, contextual borders between Contrast2 and Contrast3, etc.) by first looking at the function and then "eyeballing" those thresholds. But is that the best we can do? The difference between (Ymin / Ymax) and log(Ymin / Ymax) starts to matter a lot as soon as you start talking about "twice the contrast" or "20% more contrast", doesn't it?
- ximm 4y agoSure, perceptually uniform contrast in the sense that you can talk about things like "twice the contrast" is useful. If I had to design a modern contrast algorithm, I would try to make it perceptually uniform. But all that is irrelevant in the context of WCAG (and most other contexts). It literally only cares about thresholds.