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

Unified Diff: Source/platform/graphics/ImageFrameGenerator.h

Issue 105773003: Teach Skia to use discardable memory (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: merged and discardable 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/platform/graphics/ImageFrameGenerator.h
diff --git a/Source/platform/graphics/ImageFrameGenerator.h b/Source/platform/graphics/ImageFrameGenerator.h
index 964b0937ebfb2980e315d98610e8440b6b67ea8a..32817b48a6790cadf295c65ce5699a8a87ead421 100644
--- a/Source/platform/graphics/ImageFrameGenerator.h
+++ b/Source/platform/graphics/ImageFrameGenerator.h
@@ -66,6 +66,13 @@ public:
const ScaledImageFragment* decodeAndScale(const SkISize& scaledSize, size_t index = 0);
+ // Decodes and scales the specified frame indicated by |index|. Dimensions
+ // and output format are specified in |info|. Decoded pixels are written
+ // into |pixels| with a stride of |rowBytes|.
+ //
+ // Returns true if decoding was successful.
+ bool decodeAndScale(const SkImageInfo&, size_t index, void* pixels, size_t rowBytes);
+
void setData(PassRefPtr<SharedBuffer>, bool allDataReceived);
// Creates a new SharedBuffer containing the data received so far.

Powered by Google App Engine
This is Rietveld 408576698