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

Unified Diff: Source/core/platform/graphics/win/TransparencyWin.cpp

Issue 104023007: Refactoring ImageBuffer to decouple it from Canvas2DLayerBridge (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: build fixes for win+mac Created 7 years 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: Source/core/platform/graphics/win/TransparencyWin.cpp
diff --git a/Source/core/platform/graphics/win/TransparencyWin.cpp b/Source/core/platform/graphics/win/TransparencyWin.cpp
index 0b79aa3bc6ff2e82f4f06963d0f1cbb41c9fff9c..77a60d62a36222aa8b376fb46cdd26e092373b42 100644
--- a/Source/core/platform/graphics/win/TransparencyWin.cpp
+++ b/Source/core/platform/graphics/win/TransparencyWin.cpp
@@ -34,6 +34,7 @@
#include "core/platform/graphics/SimpleFontData.h"
#include "core/platform/graphics/skia/SkiaUtils.h"
#include "core/platform/graphics/win/TransparencyWin.h"
+#include "platform/graphics/UnacceleratedImageBufferSurface.h"
#include "SkColorPriv.h"
#include "skia/ext/platform_canvas.h"
@@ -101,7 +102,9 @@ class TransparencyWin::OwnedBuffers {
public:
OwnedBuffers(const IntSize& size, bool needReferenceBuffer)
{
- m_destBitmap = ImageBuffer::create(size, 1);
+ OwnPtr<ImageBufferSurface> surface = adoptPtr(new UnacceleratedImageBufferSurface(size));
+ if (surface->isValid())
+ m_destBitmap = adoptPtr(new ImageBuffer(surface.release()));
if (needReferenceBuffer) {
m_referenceBitmap.setConfig(SkBitmap::kARGB_8888_Config, size.width(), size.height());

Powered by Google App Engine
This is Rietveld 408576698