aboutsummaryrefslogtreecommitdiffhomepage
path: root/samplecode/SampleText.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'samplecode/SampleText.cpp')
-rw-r--r--samplecode/SampleText.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/samplecode/SampleText.cpp b/samplecode/SampleText.cpp
index ee447d3066..5873091836 100644
--- a/samplecode/SampleText.cpp
+++ b/samplecode/SampleText.cpp
@@ -48,10 +48,21 @@ public:
// if (c < min) c = min;
return c;
}
+
+#ifdef SK_DEVELOPER
+ virtual void toString(SkString* str) const SK_OVERRIDE {
+ str->append("ReduceNoise: (");
+ this->INHERITED::toString(str);
+ str->append(")");
+ }
+#endif
+
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(ReduceNoise)
private:
ReduceNoise(SkFlattenableReadBuffer& rb) : SkKernel33ProcMaskFilter(rb) {}
+
+ typedef SkKernel33ProcMaskFilter INHERITED;
};
class Darken : public SkKernel33ProcMaskFilter {
@@ -69,10 +80,21 @@ public:
SkASSERT(f >= 0 && f <= 1);
return (int)(f * 255);
}
+
+#ifdef SK_DEVELOPER
+ virtual void toString(SkString* str) const SK_OVERRIDE {
+ str->append("Darken: (");
+ this->INHERITED::toString(str);
+ str->append(")");
+ }
+#endif
+
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(Darken)
private:
Darken(SkFlattenableReadBuffer& rb) : SkKernel33ProcMaskFilter(rb) {}
+
+ typedef SkKernel33ProcMaskFilter INHERITED;
};
static SkMaskFilter* makemf() { return new Darken(0x30); }