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

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

Issue 2069143002: Limit the number of accelerated canvases that can exist in a render process (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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/ImageBuffer.h
diff --git a/third_party/WebKit/Source/platform/graphics/ImageBuffer.h b/third_party/WebKit/Source/platform/graphics/ImageBuffer.h
index 4e52a0b58ee33107fd1a6c8345929dd17352fe75..20bcd7638ca5a9908c04678e4172cc4600dea043 100644
--- a/third_party/WebKit/Source/platform/graphics/ImageBuffer.h
+++ b/third_party/WebKit/Source/platform/graphics/ImageBuffer.h
@@ -73,7 +73,8 @@ enum Multiply {
};
class PLATFORM_EXPORT ImageBuffer {
- WTF_MAKE_NONCOPYABLE(ImageBuffer); USING_FAST_MALLOC(ImageBuffer);
+ WTF_MAKE_NONCOPYABLE(ImageBuffer);
+ USING_FAST_MALLOC(ImageBuffer);
public:
static PassOwnPtr<ImageBuffer> create(const IntSize&, OpacityMode = NonOpaque, ImageInitializationMode = InitializeImagePixels);
static PassOwnPtr<ImageBuffer> create(PassOwnPtr<ImageBufferSurface>);
@@ -142,6 +143,7 @@ public:
void updateGPUMemoryUsage() const;
static intptr_t getGlobalGPUMemoryUsage() { return s_globalGPUMemoryUsage; }
+ static unsigned getGlobalAcceleratedImageBufferCount() { return s_globalAcceleratedImageBufferCount; }
intptr_t getGPUMemoryUsage() { return m_gpuMemoryUsage; }
protected:
@@ -159,6 +161,7 @@ private:
mutable intptr_t m_gpuMemoryUsage;
static intptr_t s_globalGPUMemoryUsage;
+ static unsigned s_globalAcceleratedImageBufferCount;
};
struct ImageDataBuffer {

Powered by Google App Engine
This is Rietveld 408576698