diff options
Diffstat (limited to 'chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h')
-rw-r--r-- | chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h b/chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h index b4a546d4c03..2e0197b412f 100644 --- a/chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h +++ b/chromium/third_party/blink/renderer/platform/graphics/canvas_resource_provider.h @@ -148,6 +148,13 @@ class PLATFORM_EXPORT CanvasResourceProvider base::WeakPtr<WebGraphicsContext3DProviderWrapper>, base::WeakPtr<CanvasResourceDispatcher>); + // Its important to use this method for generating PaintImage wrapped canvas + // snapshots to get a cache hit from cc's ImageDecodeCache. This method + // ensures that the PaintImage ID for the snapshot, used for keying + // decodes/uploads in the cache is invalidated only when the canvas contents + // change. + cc::PaintImage MakeImageSnapshot(); + private: class CanvasImageProvider : public cc::ImageProvider { public: |