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

Unified Diff: include/core/SkPicture.h

Issue 225283014: Convert SkPicture's generation ID to a unique ID (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 6 years, 8 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 | « no previous file | include/core/SkTypes.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkPicture.h
===================================================================
--- include/core/SkPicture.h (revision 14074)
+++ include/core/SkPicture.h (working copy)
@@ -201,14 +201,12 @@
*/
int height() const { return fHeight; }
- static const uint32_t kInvalidGenID = 0;
-
/** Return a non-zero, unique value representing the picture. This call is
only valid when not recording. Between a beginRecording/endRecording
- pair it will just return 0 (the invalid gen ID). Each beginRecording/
+ pair it will just return 0 (the invalid ID). Each beginRecording/
endRecording pair will cause a different generation ID to be returned.
*/
- uint32_t getGenerationID() const;
+ uint32_t uniqueID() const;
/**
* Function to encode an SkBitmap to an SkData. A function with this
@@ -308,7 +306,7 @@
static const uint32_t MIN_PICTURE_VERSION = 19;
static const uint32_t CURRENT_PICTURE_VERSION = 22;
- mutable uint32_t fGenerationID;
+ mutable uint32_t fUniqueID;
// fPlayback, fRecord, fWidth & fHeight are protected to allow derived classes to
// install their own SkPicturePlayback-derived players,SkPictureRecord-derived
@@ -318,7 +316,7 @@
int fWidth, fHeight;
const AccelData* fAccelData;
- void needsNewGenID() { fGenerationID = kInvalidGenID; }
+ void needsNewGenID() { fUniqueID = SK_InvalidGenID; }
// Create a new SkPicture from an existing SkPicturePlayback. Ref count of
// playback is unchanged.
« no previous file with comments | « no previous file | include/core/SkTypes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698