Re: [csswg-drafts] [css-color-4] Gamut Mapping with Oklch - Odd Results (#7071)

> Is it possible that the values in your interpolation go outside the spectral locus and are not real colors? 

It may. And I could certainly analyze and plot the point relative to the spectral locus, but I'm probably less concerned with the *why* as much as I am with understanding whether this is truly the results that are desired for the gamut mapping algorithm in CSS.

Every color space has strengths and weaknesses. Oklab/Oklch is generally a far better interpolation space than Lch. What I am questioning is whether it works as well as the gamut mapping space (at least in the algorithm's current form). 

There are a number of cases where I think a user would get something saner than maybe what is returned with using Oklch (as the algorithm currently works). Even in the example where we are interpolating in Oklch and then mapping with Oklch, the transition to blue has a very sharp transition. This is exaggerated far more in the Lch interpolation/Oklch mapping.

I guess what it boils down to is what the priority in the gamut mapping algorithm is. Personally, I'd take slightly less "accurate" mapping if, visually, it gave something close enough to what I'd expect in most common, practical use cases. Jarring transitions, like in the opening post, makes it far less attractive.

I just figured it was worth bringing up as a discussion point.

-- 
GitHub Notification of comment by facelessuser
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7071#issuecomment-1047225018 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 21 February 2022 21:01:24 UTC