Title: [291493] trunk
- Revision
- 291493
- Author
- [email protected]
- Date
- 2022-03-18 12:36:58 -0700 (Fri, 18 Mar 2022)
Log Message
REGRESSION (r290628): Scrubber makes a visual trail when scrubbing on tv.youtube.com
https://bugs.webkit.org/show_bug.cgi?id=238047
<rdar://problem/90451319>
Reviewed by Alan Bujtas.
Source/WebCore:
In r290628 I added a call to clearRepaintRects() when changing the backing sharing
target layer for a RenderLayer. However, for a layer using backing sharing, this
gets called twice during a normal compositing update, which has the effect of
clearing the cached repaint rects so that a layer repaint always computes new rects.
Thus, if a layer moved, we'd fail to repaint the old rect.
RenderLayerBacking::setBackingSharingLayers() already has logic to update repaint
rects when state changes, so we don't need this clearing.
Test: compositing/repaint/move-backing-sharing-layer.html
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::setBackingProviderLayer):
LayoutTests:
* compositing/repaint/move-backing-sharing-layer-expected.txt: Added.
* compositing/repaint/move-backing-sharing-layer.html: Added.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (291492 => 291493)
--- trunk/LayoutTests/ChangeLog 2022-03-18 19:19:35 UTC (rev 291492)
+++ trunk/LayoutTests/ChangeLog 2022-03-18 19:36:58 UTC (rev 291493)
@@ -1,3 +1,14 @@
+2022-03-18 Simon Fraser <[email protected]>
+
+ REGRESSION (r290628): Scrubber makes a visual trail when scrubbing on tv.youtube.com
+ https://bugs.webkit.org/show_bug.cgi?id=238047
+ <rdar://problem/90451319>
+
+ Reviewed by Alan Bujtas.
+
+ * compositing/repaint/move-backing-sharing-layer-expected.txt: Added.
+ * compositing/repaint/move-backing-sharing-layer.html: Added.
+
2022-03-18 Philippe Normand <[email protected]>
[GStreamer] Initial import of the GstWebRTC backend
Added: trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer-expected.txt (0 => 291493)
--- trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer-expected.txt (rev 0)
+++ trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer-expected.txt 2022-03-18 19:36:58 UTC (rev 291493)
@@ -0,0 +1,27 @@
+(GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 817.00 585.00)
+ (children 1
+ (GraphicsLayer
+ (bounds 817.00 585.00)
+ (contentsOpaque 1)
+ (children 2
+ (GraphicsLayer
+ (position 8.00 13.00)
+ (bounds 20.00 20.00)
+ (contentsOpaque 1)
+ )
+ (GraphicsLayer
+ (position 15.00 15.00)
+ (bounds 802.00 202.00)
+ (drawsContent 1)
+ (repaint rects
+ (rect 201.00 51.00 100.00 100.00)
+ (rect 401.00 51.00 100.00 100.00)
+ )
+ )
+ )
+ )
+ )
+)
+
Added: trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer.html (0 => 291493)
--- trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer.html (rev 0)
+++ trunk/LayoutTests/compositing/repaint/move-backing-sharing-layer.html 2022-03-18 19:36:58 UTC (rev 291493)
@@ -0,0 +1,73 @@
+<!DOCTYPE html>
+<html>
+<head>
+ <style>
+ .trigger {
+ position: absolute;
+ width: 20px;
+ height: 20px;
+ transform: translateZ(0);
+ background-color: silver;
+ }
+
+ .composited-sharing {
+ position: absolute;
+ top: 15px;
+ left: 15px;
+ width: 800px;
+ height: 200px;
+ border: 1px solid blue;
+ }
+
+ .test {
+ position: absolute;
+ transform: scale(1, 1);
+ top: 50px;
+ left: 100px;
+ background: orange;
+ height: 100px;
+ width: 100px;
+ }
+
+ body.changed .test {
+ left: 200px;
+ }
+
+ body.changed.again .test {
+ left: 400px;
+ }
+ </style>
+ <script src=""
+ <script>
+ if (window.testRunner) {
+ testRunner.dumpAsText();
+ testRunner.waitUntilDone();
+ }
+
+ window.addEventListener('load', () => {
+ setTimeout(async () => {
+ document.body.classList.add('changed');
+ await UIHelper.renderingUpdate();
+
+ if (window.internals)
+ window.internals.startTrackingRepaints();
+
+ document.body.classList.add('again');
+
+ if (window.internals)
+ document.getElementById('layers').textContent = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_REPAINT_RECTS);
+
+ if (window.testRunner)
+ testRunner.notifyDone();
+ }, 0);
+ }, false);
+ </script>
+</head>
+<body>
+ <div class="trigger"></div>
+ <div class="composited-sharing">
+ <div class="test"></div>
+ </div>
+<pre id="layers"></pre>
+</body>
+</html>
Added: trunk/LayoutTests/platform/ios-wk2/compositing/repaint/move-backing-sharing-layer-expected.txt (0 => 291493)
--- trunk/LayoutTests/platform/ios-wk2/compositing/repaint/move-backing-sharing-layer-expected.txt (rev 0)
+++ trunk/LayoutTests/platform/ios-wk2/compositing/repaint/move-backing-sharing-layer-expected.txt 2022-03-18 19:36:58 UTC (rev 291493)
@@ -0,0 +1,27 @@
+(GraphicsLayer
+ (anchor 0.00 0.00)
+ (bounds 817.00 600.00)
+ (children 1
+ (GraphicsLayer
+ (bounds 817.00 600.00)
+ (contentsOpaque 1)
+ (children 2
+ (GraphicsLayer
+ (position 8.00 13.00)
+ (bounds 20.00 20.00)
+ (contentsOpaque 1)
+ )
+ (GraphicsLayer
+ (position 15.00 15.00)
+ (bounds 802.00 202.00)
+ (drawsContent 1)
+ (repaint rects
+ (rect 201.00 51.00 100.00 100.00)
+ (rect 401.00 51.00 100.00 100.00)
+ )
+ )
+ )
+ )
+ )
+)
+
Modified: trunk/Source/WebCore/ChangeLog (291492 => 291493)
--- trunk/Source/WebCore/ChangeLog 2022-03-18 19:19:35 UTC (rev 291492)
+++ trunk/Source/WebCore/ChangeLog 2022-03-18 19:36:58 UTC (rev 291493)
@@ -1,3 +1,25 @@
+2022-03-18 Simon Fraser <[email protected]>
+
+ REGRESSION (r290628): Scrubber makes a visual trail when scrubbing on tv.youtube.com
+ https://bugs.webkit.org/show_bug.cgi?id=238047
+ <rdar://problem/90451319>
+
+ Reviewed by Alan Bujtas.
+
+ In r290628 I added a call to clearRepaintRects() when changing the backing sharing
+ target layer for a RenderLayer. However, for a layer using backing sharing, this
+ gets called twice during a normal compositing update, which has the effect of
+ clearing the cached repaint rects so that a layer repaint always computes new rects.
+ Thus, if a layer moved, we'd fail to repaint the old rect.
+
+ RenderLayerBacking::setBackingSharingLayers() already has logic to update repaint
+ rects when state changes, so we don't need this clearing.
+
+ Test: compositing/repaint/move-backing-sharing-layer.html
+
+ * rendering/RenderLayer.cpp:
+ (WebCore::RenderLayer::setBackingProviderLayer):
+
2022-03-18 Enrique Ocaña González <[email protected]>
[GStreamer] Add stop position to the range request
Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (291492 => 291493)
--- trunk/Source/WebCore/rendering/RenderLayer.cpp 2022-03-18 19:19:35 UTC (rev 291492)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp 2022-03-18 19:36:58 UTC (rev 291493)
@@ -1958,10 +1958,8 @@
if (backingProvider == m_backingProviderLayer)
return;
- if (!renderer().renderTreeBeingDestroyed()) {
+ if (!renderer().renderTreeBeingDestroyed())
clearClipRectsIncludingDescendants();
- clearRepaintRects();
- }
m_backingProviderLayer = backingProvider;
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes