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

Unified Diff: gm/gm_expectations.h

Issue 17365002: GM: add --writeChecksumBasedFilenames option (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: sync_to_r9681 Created 7 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
« no previous file with comments | « no previous file | gm/gm_expectations.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/gm_expectations.h
===================================================================
--- gm/gm_expectations.h (revision 9681)
+++ gm/gm_expectations.h (working copy)
@@ -76,12 +76,33 @@
*/
Json::Value asJsonTypeValuePair() const;
+ /**
+ * Returns the hashtype, such as "bitmap-64bitMD5", as an SkString.
+ */
+ SkString getHashType() const;
+
+ /**
+ * Returns the hash digest value, such as "12345", as an SkString.
+ */
+ SkString getDigestValue() const;
+
private:
bool fIsValid; // always check this first--if it's false, other fields are meaningless
uint64_t fHashDigest;
};
/**
+ * Encapsulates an SkBitmap and its GmResultDigest, guaranteed to keep them in sync.
+ */
+ class BitmapAndDigest {
+ public:
+ BitmapAndDigest(const SkBitmap &bitmap) : fBitmap(bitmap), fDigest(bitmap) {}
+
+ const SkBitmap fBitmap;
+ const GmResultDigest fDigest;
+ };
+
+ /**
* Test expectations (allowed image results, etc.)
*/
class Expectations {
« no previous file with comments | « no previous file | gm/gm_expectations.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698