aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects/SkAlphaThresholdFilter.cpp
diff options
context:
space:
mode:
authorGravatar halcanary <halcanary@google.com>2015-12-07 10:29:54 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-12-07 10:29:54 -0800
commit0745653a677f405bb683b7f7a71b56a7e0dc7921 (patch)
treefbee8da1a19961f9073fe52aea529769d2e7d5d4 /src/effects/SkAlphaThresholdFilter.cpp
parent1d265ca85f51ea1ba087ca4d0f80b008c256a47d (diff)
SkAlphaThresholdFilter.h allow flattening
Motivation: allows this: #include "SkAlphaThresholdFilter.h" void init() { SkAlphaThresholdFilter::InitializeFlattenables(); } BUG=skia:4613 Review URL: https://codereview.chromium.org/1500373003
Diffstat (limited to 'src/effects/SkAlphaThresholdFilter.cpp')
-rw-r--r--src/effects/SkAlphaThresholdFilter.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/effects/SkAlphaThresholdFilter.cpp b/src/effects/SkAlphaThresholdFilter.cpp
index 661d0d362a..b6be944220 100644
--- a/src/effects/SkAlphaThresholdFilter.cpp
+++ b/src/effects/SkAlphaThresholdFilter.cpp
@@ -22,6 +22,7 @@ public:
SK_TO_STRING_OVERRIDE()
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkAlphaThresholdFilterImpl)
+ friend void SkAlphaThresholdFilter::InitializeFlattenables();
protected:
void flatten(SkWriteBuffer&) const override;
@@ -40,6 +41,11 @@ private:
typedef SkImageFilter INHERITED;
};
+SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkAlphaThresholdFilter)
+ SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkAlphaThresholdFilterImpl)
+SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END
+
+
SkImageFilter* SkAlphaThresholdFilter::Create(const SkRegion& region,
SkScalar innerThreshold,
SkScalar outerThreshold,