Re: [csswg-drafts] [css-color-4] CSS gamut mapping algorithm pseudocode can result in infinite looping for some inputs (#6999)

Thinking about this geometrically, I think this can also be fixed by clamping the origin_OKLCH lightness values between 0 and 1, since regardless of hue, the chroma should be reducible to an in gamut value in that lightness range. In practice, this probably means just returning { 1 1 1 origin.alpha } if lightness >= 1 and { 0 0 0 origin.alpha } if lightness is 0.

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


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

Received on Monday, 31 January 2022 14:53:28 UTC