Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 9a32d7b70a01c733ebc0c2047447ffdde4562e61
      
https://github.com/WebKit/WebKit/commit/9a32d7b70a01c733ebc0c2047447ffdde4562e61
  Author: Nikolas Zimmermann <[email protected]>
  Date:   2026-09-21 (Mon, 21 Sep 2026)

  Changed paths:
    M Source/WebCore/platform/graphics/skia/SkiaBackingStore.cpp

  Log Message:
  -----------
  [GTK][WPE] Do not rasterize the part of a tile that the clip drops
https://bugs.webkit.org/show_bug.cgi?id=324631

Reviewed by Carlos Garcia Campos.

A backing store draws each tile as one quad, at the full size of the tile. The
clip then throws away the parts that are not visible, but the rasterizer has
already filled them.

In a normal frame this costs almost nothing, because a tile is about as large as
the clip. It costs a lot when a subtree is painted into a surface that covers
one layer only, with the layer transform on the canvas.

Cut the quad down to the clip before drawing it, and cut the source rect the
same way. A tile that already fits inside the clip is drawn as before.

* Source/WebCore/platform/graphics/skia/SkiaBackingStore.cpp:
(WebCore::clipTileToBounds):
(WebCore::SkiaBackingStore::paintToCanvas):
(WebCore::SkiaBackingStore::appendImageSetEntries const):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to