WebKit Bugzilla
Attachment 359456 Details for
Bug 192554
: Rendering artifact on subpixel positions
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-192554-20190118092728.patch (text/plain), 6.04 KB, created by
Karl Leplat
on 2019-01-18 00:28:06 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Karl Leplat
Created:
2019-01-18 00:28:06 PST
Size:
6.04 KB
patch
obsolete
>Subversion Revision: 240106 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index e1656dffb383fc9bc35599fdae6f61228489b488..5c263cde71d1ec10576542ddd2d19e06cef51f38 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,16 @@ >+2019-01-18 Karl Leplat <karl.leplat_ext@softathome.com> >+ >+ [GTK][WPE] Rendering artifact on subpixel positions >+ https://bugs.webkit.org/show_bug.cgi?id=192554 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Test: compositing/repaint/repaint-element-on-subpixel-position.html >+ >+ * rendering/RenderLayerBacking.cpp: >+ (WebCore::subpixelOffsetFromRendererChanged): Force repainting >+ whenever the subpixel changes. >+ > 2019-01-16 Simon Fraser <simon.fraser@apple.com> > > Stub out scrolling tree classes for overflow scrolling nodes on macOS >diff --git a/Source/WebCore/rendering/RenderLayerBacking.cpp b/Source/WebCore/rendering/RenderLayerBacking.cpp >index b64f8f769012d716896d6cba4bb5c693648a1850..e71f70a8f50dcfc34c7ee9126df0343b6d06e2ac 100644 >--- a/Source/WebCore/rendering/RenderLayerBacking.cpp >+++ b/Source/WebCore/rendering/RenderLayerBacking.cpp >@@ -813,9 +813,8 @@ static LayoutRect clipBox(RenderBox& renderer) > > static bool subpixelOffsetFromRendererChanged(const LayoutSize& oldSubpixelOffsetFromRenderer, const LayoutSize& newSubpixelOffsetFromRenderer, float deviceScaleFactor) > { >- FloatSize previous = snapSizeToDevicePixel(oldSubpixelOffsetFromRenderer, LayoutPoint(), deviceScaleFactor); >- FloatSize current = snapSizeToDevicePixel(newSubpixelOffsetFromRenderer, LayoutPoint(), deviceScaleFactor); >- return previous != current; >+ //FIXME: A fine tuning have to be done to avoid to repaint too much. >+ return oldSubpixelOffsetFromRenderer != newSubpixelOffsetFromRenderer; > } > > static FloatSize subpixelForLayerPainting(const LayoutPoint& point, float pixelSnappingFactor) >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index e856254f6b5005505f8a1dd3c3c961e87901d7c1..6b42a4381a9839dfc7cc90d818e8dd7ae38b8872 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,13 @@ >+2019-01-18 Karl Leplat <karl.leplat_ext@softathome.com> >+ >+ [GTK][WPE] Rendering artifact on subpixel positions >+ https://bugs.webkit.org/show_bug.cgi?id=192554 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * compositing/repaint/repaint-element-on-subpixel-position-expected.txt: Added. >+ * compositing/repaint/repaint-element-on-subpixel-position.html: Added. >+ > 2019-01-16 Alicia Boya GarcÃa <aboya@igalia.com> > > Unreviewed GTK and WPE test gardening. >diff --git a/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position-expected.txt b/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..453bb27716df88ab8b106bdb89f76fd12251ded8 >--- /dev/null >+++ b/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position-expected.txt >@@ -0,0 +1,42 @@ >+. >+. >+(GraphicsLayer >+ (anchor 0.00 0.00) >+ (bounds 800.00 600.00) >+ (children 1 >+ (GraphicsLayer >+ (bounds 800.00 600.00) >+ (contentsOpaque 1) >+ (children 5 >+ (GraphicsLayer >+ (bounds 800.00 600.00) >+ ) >+ (GraphicsLayer >+ (position 8.00 19.00) >+ (bounds 0.00 1.00) >+ ) >+ (GraphicsLayer >+ (position 8.00 19.00) >+ (bounds 292.00 63.00) >+ ) >+ (GraphicsLayer >+ (position 8.00 19.00) >+ (bounds 292.00 32.00) >+ (drawsContent 1) >+ (repaint rects >+ (rect 0.00 0.00 292.00 32.00) >+ ) >+ ) >+ (GraphicsLayer >+ (position 8.00 50.00) >+ (bounds 292.00 32.00) >+ (drawsContent 1) >+ (repaint rects >+ (rect 0.00 0.00 292.00 32.00) >+ ) >+ ) >+ ) >+ ) >+ ) >+) >+ >diff --git a/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position.html b/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position.html >new file mode 100644 >index 0000000000000000000000000000000000000000..fab3f4e9d5331f0d433de468a0f331086c151cc4 >--- /dev/null >+++ b/LayoutTests/compositing/repaint/repaint-element-on-subpixel-position.html >@@ -0,0 +1,74 @@ >+<!DOCTYPE html> >+<html> >+<head> >+ >+ <style type="text/css"> >+ >+ .dummyTitle { >+ font-size: 2.0em; >+ margin-bottom: 0.6em; >+ } >+ >+ .list_select { >+ width: 14em; >+ font-size: 1.3em; >+ } >+ >+ .list_select_options { >+ position: relative; >+ } >+ >+ .list_select_options_slider { >+ position: absolute; >+ width: 100%; >+ } >+ >+ .list_option { >+ position: relative; >+ height: 1.5em; >+ width: 86%; >+ background-color: #333; >+ color: white; >+ padding: 0 7%; >+ } >+ >+ .list_option.selected { >+ background-color: #F60; >+ } >+ </style> >+ >+ <script src="../../fast/repaint/resources/repaint.js"></script> >+ <script> >+ if (window.testRunner) >+ testRunner.dumpAsText(); >+ >+ function repaintTest() { >+ if (window.internals) >+ window.internals.startTrackingRepaints(); >+ >+ document.getElementById("listselect").style.top = "0.2px"; >+ >+ if (window.testRunner && window.internals) { >+ document.getElementById('repaintRects').textContent = window.internals.layerTreeAsText(document, internals.LAYER_TREE_INCLUDES_REPAINT_RECTS); >+ window.internals.stopTrackingRepaints(); >+ testRunner.notifyDone(); >+ } >+ } >+ >+ </script> >+</head> >+<body onload="runRepaintTest()"> >+ <div id="forceAcceleratedCompositing" style="position:absolute;left:0;right:0;top:0;bottom:0;-webkit-transform: translate3d(0, 0, 0);"></div> >+ >+ <div class="dummyTitle"></div> >+ <div class="list_select"> >+ <div class="list_select_options"> >+ <div id="listselect" class="list_select_options_slider"> >+ <div id="opt1" class="list_option">.</div> >+ <div id="opt2" class="list_option">.</div> >+ </div> >+ </div> >+ </div> >+ <pre id="repaintRects">Layer tree goes here"</pre> >+</body> >+</html>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 192554
:
356955
|
356956
|
356957
|
356958
|
356959
|
357048
|
357050
|
357051
|
357056
|
357057
|
357121
|
357124
|
357127
|
357132
|
357134
|
357138
|
357180
|
357566
|
358887
|
358888
|
358914
|
358918
|
358947
|
359367
|
359370
|
359371
|
359372
|
359373
|
359377
|
359378
|
359456
|
359458
|
359488
|
359552
|
363081