[webkit-reviews] review granted: [Bug 233862] [CSS Color 5] Update color-mix() to support srgb-linear and alpha premultiplication : [Attachment 445988] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Dec 5 19:34:23 PST 2021


Cameron McCormack (:heycam) <heycam at apple.com> has granted Sam Weinig
<sam at webkit.org>'s request for review:
Bug 233862: [CSS Color 5] Update color-mix() to support srgb-linear and alpha
premultiplication
https://bugs.webkit.org/show_bug.cgi?id=233862

Attachment 445988: Patch

https://bugs.webkit.org/attachment.cgi?id=445988&action=review




--- Comment #2 from Cameron McCormack (:heycam) <heycam at apple.com> ---
Comment on attachment 445988
  --> https://bugs.webkit.org/attachment.cgi?id=445988
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=445988&action=review

I didn't look at the test changes closely.

> Source/WebCore/platform/graphics/ColorInterpolation.h:282
> +	   WebCore::ColorInterpolationColorSpace::SRGB,
> +	   WebCore::ColorInterpolationColorSpace::XYZD50,

Missing SRGBLinear.

> Source/WebCore/platform/graphics/ColorNormalization.h:64
> +template<typename ComponentType> inline ComponentType
normalizeHue(ComponentType hue)
> +{
> +    return std::fmod(std::fmod(hue, 360.0) + 360.0, 360.0);
> +}

Do we want to try to stick to floats and use fmodf when ComponentType is a
float?


More information about the webkit-reviews mailing list