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

Unified Diff: include/core/SkMallocPixelRef.h

Issue 110593003: Add onNewLockPixels, that returns rowbytes and relies on info in pixelref (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 12 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
« no previous file with comments | « include/core/SkBitmapDevice.h ('k') | include/core/SkPixelRef.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkMallocPixelRef.h
diff --git a/include/core/SkMallocPixelRef.h b/include/core/SkMallocPixelRef.h
index 272dc21fd872e34c4a98ac4d0530ac6751f56137..c40afc433aca6a403e7ed1b25af65148172c6e90 100644
--- a/include/core/SkMallocPixelRef.h
+++ b/include/core/SkMallocPixelRef.h
@@ -32,11 +32,9 @@ public:
/**
* Return a new SkMallocPixelRef, automatically allocating storage for the
- * pixels.
- *
- * If rowBytes is 0, an optimal value will be chosen automatically.
- * If rowBytes is > 0, then it will be used, unless it is invald for the
- * specified info, in which case NULL will be returned (failure).
+ * pixels. If rowBytes are 0, an optimal value will be chosen automatically.
+ * If rowBytes is > 0, then it will be respected, or NULL will be returned
+ * if rowBytes is invalid for the specified info.
*
* This pixelref will ref() the specified colortable (if not NULL).
*
@@ -90,7 +88,7 @@ protected:
SkMallocPixelRef(SkFlattenableReadBuffer& buffer);
virtual ~SkMallocPixelRef();
- virtual void* onLockPixels(SkColorTable**) SK_OVERRIDE;
+ virtual bool onNewLockPixels(LockRec*) SK_OVERRIDE;
virtual void onUnlockPixels() SK_OVERRIDE;
virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE;
virtual size_t getAllocatedSizeInBytes() const SK_OVERRIDE;
« no previous file with comments | « include/core/SkBitmapDevice.h ('k') | include/core/SkPixelRef.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698