Title: [269578] trunk
Revision
269578
Author
cl...@igalia.com
Date
2020-11-09 02:19:34 -0800 (Mon, 09 Nov 2020)

Log Message

REGRESSION(r269503): [GTK][WPE] >200 tests are failing
https://bugs.webkit.org/show_bug.cgi?id=218654
<rdar://problem/71116949>

Reviewed by Žan Doberšek.

Source/WebCore:

Replace the NativeImagePtr calls with ImageBuffer::draw. With the
cairo implementation, in the cases where it's possible, it amounts to
the same thing, but the draw implementation also handles cases that
the previous patch didn't.

* platform/graphics/cairo/GraphicsContextImplCairo.cpp:
(WebCore::GraphicsContextImplCairo::drawImageBuffer):

LayoutTests:

Mark 5 canvas tests as passing.

* platform/glib/TestExpectations:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (269577 => 269578)


--- trunk/LayoutTests/ChangeLog	2020-11-09 08:20:03 UTC (rev 269577)
+++ trunk/LayoutTests/ChangeLog	2020-11-09 10:19:34 UTC (rev 269578)
@@ -1,3 +1,15 @@
+2020-11-09  Chris Lord  <cl...@igalia.com>
+
+        REGRESSION(r269503): [GTK][WPE] >200 tests are failing
+        https://bugs.webkit.org/show_bug.cgi?id=218654
+        <rdar://problem/71116949>
+
+        Reviewed by Žan Doberšek.
+
+        Mark 5 canvas tests as passing.
+
+        * platform/glib/TestExpectations:
+
 2020-11-08  Lauro Moura  <lmo...@igalia.com>
 
         [GLIB] Rebaseline and gardening

Modified: trunk/LayoutTests/platform/glib/TestExpectations (269577 => 269578)


--- trunk/LayoutTests/platform/glib/TestExpectations	2020-11-09 08:20:03 UTC (rev 269577)
+++ trunk/LayoutTests/platform/glib/TestExpectations	2020-11-09 10:19:34 UTC (rev 269578)
@@ -198,12 +198,6 @@
 # Cairo-related bugs
 #////////////////////////////////////////////////////////////////////////////////////////
 
-webkit.org/b/218654 canvas/philip/tests/2d.drawImage.self.2.html [ Failure ]
-webkit.org/b/218654 imported/w3c/canvas/2d.drawImage.self.2.html  [ Failure ]
-webkit.org/b/218654 imported/w3c/web-platform-tests/html/canvas/element/drawing-images-to-the-canvas/2d.drawImage.self.2.html [ Failure ]
-webkit.org/b/218654 imported/w3c/web-platform-tests/html/canvas/offscreen/drawing-images-to-the-canvas/2d.drawImage.self.2.html [ Failure ]
-webkit.org/b/218654 imported/w3c/web-platform-tests/html/canvas/offscreen/drawing-images-to-the-canvas/2d.drawImage.self.2.worker.html [ Failure ]
-
 #////////////////////////////////////////////////////////////////////////////////////////
 # End of Cairo-related bugs
 #////////////////////////////////////////////////////////////////////////////////////////

Modified: trunk/Source/WebCore/ChangeLog (269577 => 269578)


--- trunk/Source/WebCore/ChangeLog	2020-11-09 08:20:03 UTC (rev 269577)
+++ trunk/Source/WebCore/ChangeLog	2020-11-09 10:19:34 UTC (rev 269578)
@@ -1,3 +1,19 @@
+2020-11-09  Chris Lord  <cl...@igalia.com>
+
+        REGRESSION(r269503): [GTK][WPE] >200 tests are failing
+        https://bugs.webkit.org/show_bug.cgi?id=218654
+        <rdar://problem/71116949>
+
+        Reviewed by Žan Doberšek.
+
+        Replace the NativeImagePtr calls with ImageBuffer::draw. With the
+        cairo implementation, in the cases where it's possible, it amounts to
+        the same thing, but the draw implementation also handles cases that
+        the previous patch didn't.
+
+        * platform/graphics/cairo/GraphicsContextImplCairo.cpp:
+        (WebCore::GraphicsContextImplCairo::drawImageBuffer):
+
 2020-11-08  Zalan Bujtas  <za...@apple.com>
 
         [LFC][Integration] Cleanup LayoutIntegration::Line interface

Modified: trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextImplCairo.cpp (269577 => 269578)


--- trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextImplCairo.cpp	2020-11-09 08:20:03 UTC (rev 269577)
+++ trunk/Source/WebCore/platform/graphics/cairo/GraphicsContextImplCairo.cpp	2020-11-09 10:19:34 UTC (rev 269578)
@@ -281,10 +281,7 @@
 
 void GraphicsContextImplCairo::drawImageBuffer(ImageBuffer& image, const FloatRect& destRect, const FloatRect& srcRect, const ImagePaintingOptions& options)
 {
-    if (auto nativeImage = image.copyNativeImage(DontCopyBackingStore)) {
-        auto& state = graphicsContext().state();
-        Cairo::drawNativeImage(m_platformContext, nativeImage.get(), destRect, srcRect, { options, state.imageInterpolationQuality }, state.alpha, Cairo::ShadowState(state));
-    }
+    image.draw(graphicsContext(), destRect, srcRect, options);
 }
 
 void GraphicsContextImplCairo::drawNativeImage(const NativeImagePtr& image, const FloatSize& imageSize, const FloatRect& destRect, const FloatRect& srcRect, const ImagePaintingOptions& options)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to