Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(890)

Unified Diff: third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h

Issue 2212163002: Add some plumbing for the color management of canvases (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase again Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h
diff --git a/third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h b/third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h
index 7785f3b013bd72ada2cc7b2c63dd1ded89afbdd5..6ba47bdfa6c6b07a87ebf01179d70f6206dbc915 100644
--- a/third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h
+++ b/third_party/WebKit/Source/platform/graphics/Canvas2DImageBufferSurface.h
@@ -39,15 +39,15 @@ namespace blink {
// This shim necessary because ImageBufferSurfaces are not allowed to be RefCounted
class Canvas2DImageBufferSurface final : public ImageBufferSurface {
public:
- Canvas2DImageBufferSurface(std::unique_ptr<WebGraphicsContext3DProvider> contextProvider, const IntSize& size, int msaaSampleCount, OpacityMode opacityMode, Canvas2DLayerBridge::AccelerationMode accelerationMode)
- : ImageBufferSurface(size, opacityMode)
- , m_layerBridge(adoptRef(new Canvas2DLayerBridge(std::move(contextProvider), size, msaaSampleCount, opacityMode, accelerationMode)))
+ Canvas2DImageBufferSurface(std::unique_ptr<WebGraphicsContext3DProvider> contextProvider, const IntSize& size, int msaaSampleCount, OpacityMode opacityMode, Canvas2DLayerBridge::AccelerationMode accelerationMode, sk_sp<SkColorSpace> colorSpace)
+ : ImageBufferSurface(size, opacityMode, colorSpace)
+ , m_layerBridge(adoptRef(new Canvas2DLayerBridge(std::move(contextProvider), size, msaaSampleCount, opacityMode, accelerationMode, colorSpace)))
{
init();
}
Canvas2DImageBufferSurface(PassRefPtr<Canvas2DLayerBridge> bridge, const IntSize& size)
- : ImageBufferSurface(size, bridge->opacityMode())
+ : ImageBufferSurface(size, bridge->opacityMode(), bridge->colorSpace())
, m_layerBridge(std::move(bridge))
{
init();

Powered by Google App Engine
This is Rietveld 408576698