-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Skia] Make GraphicsContextSkia constructor receive a SkCanvas instea…
…d of a SkSurface https://bugs.webkit.org/show_bug.cgi?id=271309 Reviewed by Alejandro G. Castro. For printing we won't have a SkSurface to pass. The constructor now receives a reference to a SkCanvas, so callers need to ensure the canvas will be alive, which is always the case except for ShareableBitmap. For that case we also include an optional destroy notify parameter that is used to release the associated SkSurface when the graphics context is destroyed. * Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp: (WebCore::GraphicsContextSkia::GraphicsContextSkia): (WebCore::GraphicsContextSkia::hasPlatformContext const): (WebCore::GraphicsContextSkia::getCTM const): (WebCore::GraphicsContextSkia::platformContext const): (WebCore::GraphicsContextSkia::save): (WebCore::GraphicsContextSkia::restore): (WebCore::GraphicsContextSkia::drawRect): (WebCore::GraphicsContextSkia::drawNativeImageInternal): (WebCore::GraphicsContextSkia::drawLine): (WebCore::GraphicsContextSkia::drawEllipse): (WebCore::GraphicsContextSkia::fillPath): (WebCore::GraphicsContextSkia::strokePath): (WebCore::GraphicsContextSkia::fillRect): (WebCore::GraphicsContextSkia::clip): (WebCore::GraphicsContextSkia::clipPath): (WebCore::GraphicsContextSkia::clipBounds const): (WebCore::GraphicsContextSkia::clipToImageBuffer): (WebCore::GraphicsContextSkia::drawDotsForDocumentMarker): (WebCore::GraphicsContextSkia::translate): (WebCore::GraphicsContextSkia::concatCTM): (WebCore::GraphicsContextSkia::setCTM): (WebCore::GraphicsContextSkia::beginTransparencyLayer): (WebCore::GraphicsContextSkia::endTransparencyLayer): (WebCore::GraphicsContextSkia::clearRect): (WebCore::GraphicsContextSkia::strokeRect): (WebCore::GraphicsContextSkia::clipOut): (WebCore::GraphicsContextSkia::rotate): (WebCore::GraphicsContextSkia::scale): (WebCore::GraphicsContextSkia::fillRoundedRectImpl): (WebCore::GraphicsContextSkia::fillRectWithRoundedHole): (WebCore::GraphicsContextSkia::drawPattern): (WebCore::GraphicsContextSkia::canvas const): Deleted. * Source/WebCore/platform/graphics/skia/GraphicsContextSkia.h: * Source/WebCore/platform/graphics/skia/ImageBufferSkiaAcceleratedBackend.cpp: (WebCore::ImageBufferSkiaAcceleratedBackend::create): * Source/WebCore/platform/graphics/skia/ImageBufferSkiaSurfaceBackend.cpp: (WebCore::ImageBufferSkiaSurfaceBackend::ImageBufferSkiaSurfaceBackend): * Source/WebCore/platform/graphics/skia/ImageBufferSkiaSurfaceBackend.h: * Source/WebCore/platform/graphics/skia/ImageBufferSkiaUnacceleratedBackend.cpp: (WebCore::ImageBufferSkiaUnacceleratedBackend::create): * Source/WebCore/platform/graphics/skia/PathSkia.cpp: (WebCore::PathSkia::strokeContains const): (WebCore::PathSkia::strokeBoundingRect const): * Source/WebCore/platform/graphics/skia/ShareableBitmapSkia.cpp: (WebCore::ShareableBitmap::createGraphicsContext): * Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsLayerSkia.cpp: (WebCore::CoordinatedGraphicsLayer::paintTile): (WebCore::CoordinatedGraphicsLayer::paintImage): * Source/WebKit/UIProcess/cairo/BackingStoreCairo.cpp: (WebKit::BackingStore::incorporateUpdate): Canonical link: https://commits.webkit.org/276408@main
- Loading branch information
1 parent
143ff2a
commit 867737f
Showing
10 changed files
with
89 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.