[webkit-changes] [WebKit/WebKit] ccbeb1: Hairline pixel crack around background-clip: text

Simon Fraser noreply at github.com
Fri Apr 28 20:30:42 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ccbeb1e341f13f05bf4167f0f7253d8d87383da0
      https://github.com/WebKit/WebKit/commit/ccbeb1e341f13f05bf4167f0f7253d8d87383da0
  Author: Simon Fraser <simon.fraser at apple.com>
  Date:   2023-04-28 (Fri, 28 Apr 2023)

  Changed paths:
    A LayoutTests/fast/css/background-clip-text-hairline-expected.html
    A LayoutTests/fast/css/background-clip-text-hairline.html
    M Source/WebCore/rendering/BackgroundPainter.cpp

  Log Message:
  -----------
  Hairline pixel crack around background-clip: text
https://bugs.webkit.org/show_bug.cgi?id=179333
rdar://54325642

Reviewed by Alan Baradlay.

When there is some non-integral transform (or a non axis-aligned transform) in the CTM, we could
show some antialiasing noise at the edge of `background-clip: text` regions. This noise was not
in the buffer used as a mask, but seemed to come from some the transparency layer operations.

We can work around it by inflating maskRect by a pixel on each size, which pads the intermediate
buffer, and the size of the transparency layer.

* LayoutTests/fast/css/background-clip-text-hairline-expected.html: Added.
* LayoutTests/fast/css/background-clip-text-hairline.html: Added.
* Source/WebCore/rendering/BackgroundPainter.cpp:
(WebCore::BackgroundPainter::paintFillLayer):

Canonical link: https://commits.webkit.org/263526@main




More information about the webkit-changes mailing list