aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkTileGridPicture.h
diff options
context:
space:
mode:
authorGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-04-13 19:09:42 +0000
committerGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2014-04-13 19:09:42 +0000
commit84b18c7e3e042bf206e1ace3d1b6ea5bb929fe51 (patch)
tree7b46e74e6212283d9efe62a7b6feaad2c009972b /include/core/SkTileGridPicture.h
parentc202ea7cc69476a20ad898d6c76bcdbcb18adf74 (diff)
split SkPictureRecorder out of SkPicture
Diffstat (limited to 'include/core/SkTileGridPicture.h')
-rw-r--r--include/core/SkTileGridPicture.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/include/core/SkTileGridPicture.h b/include/core/SkTileGridPicture.h
index af7f0e2d78..c1929f46a6 100644
--- a/include/core/SkTileGridPicture.h
+++ b/include/core/SkTileGridPicture.h
@@ -51,6 +51,23 @@ public:
private:
int fXTileCount, fYTileCount;
TileGridInfo fInfo;
+
+ typedef SkPicture INHERITED;
+};
+
+class SkTileGridPictureFactory : public SkPictureFactory {
+public:
+ SkTileGridPictureFactory(const SkTileGridPicture::TileGridInfo& info) : fInfo(info) { }
+
+ virtual SkPicture* create(int width, int height) SK_OVERRIDE {
+ return SkNEW_ARGS(SkTileGridPicture, (width, height, fInfo));
+ }
+
+protected:
+ SkTileGridPicture::TileGridInfo fInfo;
+
+private:
+ typedef SkPictureFactory INHERITED;
};
#endif