Title: [290839] trunk
- Revision
- 290839
- Author
- [email protected]
- Date
- 2022-03-04 11:40:31 -0800 (Fri, 04 Mar 2022)
Log Message
[GPU Process] Canvas compositing buffer should be created through its GraphicsContext
https://bugs.webkit.org/show_bug.cgi?id=237260
rdar://89196918
Reviewed by Simon Fraser.
Source/WebCore:
If the backend of the underlying ImageBuffer of the canvas is remote the
compositing ImageBuffer will also be remote. This will transfer the whole
compositing operation to GPUProcess.
The layout test fast/canvas/canvas-composite-canvas.html crashes because
of this bug on the GPUP layout bots.
* html/canvas/CanvasRenderingContext2DBase.cpp:
(WebCore::CanvasRenderingContext2DBase::fullCanvasCompositedDrawImage):
(WebCore::CanvasRenderingContext2DBase::createCompositingBuffer): Deleted.
* html/canvas/CanvasRenderingContext2DBase.h:
LayoutTests:
* gpu-process/TestExpectations:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (290838 => 290839)
--- trunk/LayoutTests/ChangeLog 2022-03-04 19:15:51 UTC (rev 290838)
+++ trunk/LayoutTests/ChangeLog 2022-03-04 19:40:31 UTC (rev 290839)
@@ -1,3 +1,13 @@
+2022-03-04 Said Abou-Hallawa <[email protected]>
+
+ [GPU Process] Canvas compositing buffer should be created through its GraphicsContext
+ https://bugs.webkit.org/show_bug.cgi?id=237260
+ rdar://89196918
+
+ Reviewed by Simon Fraser.
+
+ * gpu-process/TestExpectations:
+
2022-03-04 Kate Cheney <[email protected]>
CSP report does not get sent to the document in the case of a detached element
Modified: trunk/LayoutTests/gpu-process/TestExpectations (290838 => 290839)
--- trunk/LayoutTests/gpu-process/TestExpectations 2022-03-04 19:15:51 UTC (rev 290838)
+++ trunk/LayoutTests/gpu-process/TestExpectations 2022-03-04 19:40:31 UTC (rev 290839)
@@ -324,9 +324,6 @@
webkit.org/b/236927 fast/forms/autofocus-readonly-attribute.html [ Failure Pass ]
webkit.org/b/236927 fast/forms/input-text-autofocus.html [ Pass Failure ]
-# Crashes
-webkit.org/b/236929 fast/canvas/canvas-composite-canvas.html [ Crash ]
-
# Flaky timeout
webkit.org/b/236931 editing/pasteboard/dom-paste/dom-paste-same-origin.html [ Timeout Pass ]
Modified: trunk/Source/WebCore/ChangeLog (290838 => 290839)
--- trunk/Source/WebCore/ChangeLog 2022-03-04 19:15:51 UTC (rev 290838)
+++ trunk/Source/WebCore/ChangeLog 2022-03-04 19:40:31 UTC (rev 290839)
@@ -1,3 +1,23 @@
+2022-03-04 Said Abou-Hallawa <[email protected]>
+
+ [GPU Process] Canvas compositing buffer should be created through its GraphicsContext
+ https://bugs.webkit.org/show_bug.cgi?id=237260
+ rdar://89196918
+
+ Reviewed by Simon Fraser.
+
+ If the backend of the underlying ImageBuffer of the canvas is remote the
+ compositing ImageBuffer will also be remote. This will transfer the whole
+ compositing operation to GPUProcess.
+
+ The layout test fast/canvas/canvas-composite-canvas.html crashes because
+ of this bug on the GPUP layout bots.
+
+ * html/canvas/CanvasRenderingContext2DBase.cpp:
+ (WebCore::CanvasRenderingContext2DBase::fullCanvasCompositedDrawImage):
+ (WebCore::CanvasRenderingContext2DBase::createCompositingBuffer): Deleted.
+ * html/canvas/CanvasRenderingContext2DBase.h:
+
2022-03-04 Dan Glastonbury <[email protected]>
"OffscreenCanvas" in IDLs doesn't seem to be able to be compiled
Modified: trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp (290838 => 290839)
--- trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp 2022-03-04 19:15:51 UTC (rev 290838)
+++ trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.cpp 2022-03-04 19:40:31 UTC (rev 290839)
@@ -1782,11 +1782,6 @@
return bufferRect;
}
-RefPtr<ImageBuffer> CanvasRenderingContext2DBase::createCompositingBuffer(const IntRect& bufferRect)
-{
- return ImageBuffer::create(bufferRect.size(), isAccelerated() ? RenderingMode::Accelerated : RenderingMode::Unaccelerated, 1, colorSpace(), pixelFormat());
-}
-
void CanvasRenderingContext2DBase::compositeBuffer(ImageBuffer& buffer, const IntRect& bufferRect, CompositeOperator op)
{
IntRect canvasRect(0, 0, canvasBase().width(), canvasBase().height());
@@ -1829,14 +1824,14 @@
return;
}
- auto buffer = createCompositingBuffer(bufferRect);
- if (!buffer)
- return;
-
auto* c = drawingContext();
if (!c)
return;
+ auto buffer = c->createImageBuffer(bufferRect.size());
+ if (!buffer)
+ return;
+
FloatRect adjustedDest = dest;
adjustedDest.setLocation(FloatPoint(0, 0));
AffineTransform effectiveTransform = c->getCTM();
Modified: trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h (290838 => 290839)
--- trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h 2022-03-04 19:15:51 UTC (rev 290838)
+++ trunk/Source/WebCore/html/canvas/CanvasRenderingContext2DBase.h 2022-03-04 19:40:31 UTC (rev 290839)
@@ -385,7 +385,6 @@
bool rectContainsCanvas(const FloatRect&) const;
template<class T> IntRect calculateCompositingBufferRect(const T&, IntSize*);
- RefPtr<ImageBuffer> createCompositingBuffer(const IntRect&);
void compositeBuffer(ImageBuffer&, const IntRect&, CompositeOperator);
void inflateStrokeRect(FloatRect&) const;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes