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

Unified Diff: include/core/SkWriter32.h

Issue 429343004: Stopped skipping tests in dm of SkPatch (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 4 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
Index: include/core/SkWriter32.h
diff --git a/include/core/SkWriter32.h b/include/core/SkWriter32.h
index fd24ba9ddf9806b03fb67c951c4023081e84785e..737ffd581d0c6bb5c12b04ce156e03daac9f3f63 100644
--- a/include/core/SkWriter32.h
+++ b/include/core/SkWriter32.h
@@ -12,6 +12,7 @@
#include "SkData.h"
#include "SkMatrix.h"
+#include "SkPatch.h"
#include "SkPath.h"
#include "SkPoint.h"
#include "SkRRect.h"
@@ -137,6 +138,12 @@ public:
void writeRRect(const SkRRect& rrect) {
rrect.writeToMemory(this->reserve(SkRRect::kSizeInMemory));
}
+
+ void writePatch(const SkPatch& patch) {
+ size_t size = patch.writeToMemory(NULL);
+ SkASSERT(SkAlign4(size) == size);
+ patch.writeToMemory(this->reserve(size));
+ }
void writePath(const SkPath& path) {
size_t size = path.writeToMemory(NULL);

Powered by Google App Engine
This is Rietveld 408576698