aboutsummaryrefslogtreecommitdiffhomepage
path: root/dm/DMSrcSink.h
diff options
context:
space:
mode:
Diffstat (limited to 'dm/DMSrcSink.h')
-rw-r--r--dm/DMSrcSink.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/dm/DMSrcSink.h b/dm/DMSrcSink.h
index 3f3c8b2892..67128ead06 100644
--- a/dm/DMSrcSink.h
+++ b/dm/DMSrcSink.h
@@ -21,6 +21,8 @@
//#define TEST_VIA_SVG
+namespace skotty { class Animation; }
+
namespace DM {
// This is just convenience. It lets you use either return "foo" or return SkStringPrintf(...).
@@ -260,6 +262,24 @@ private:
Path fPath;
};
+class SkottySrc final : public Src {
+public:
+ explicit SkottySrc(Path path);
+
+ Error draw(SkCanvas*) const override;
+ SkISize size() const override;
+ Name name() const override;
+ bool veto(SinkFlags) const override;
+
+private:
+ // Generates a kTileCount x kTileCount filmstrip with evenly distributed frames.
+ static constexpr int kTileCount = 5;
+
+ Name fName;
+ SkISize fTileSize = SkISize::MakeEmpty();
+ std::unique_ptr<skotty::Animation> fAnimation;
+};
+
#if defined(SK_XML)
} // namespace DM