aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects
diff options
context:
space:
mode:
authorGravatar Robert Phillips <robertphillips@google.com>2017-03-28 11:59:48 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-03-28 16:36:54 +0000
commita2cedff029dcae604ce39b119d08c01ed6ad2ce8 (patch)
tree861735fdb9e418758a304b6a436f18e6ae0f1d10 /src/effects
parentd2adc66efec8a172b71bf5572fbedde064025825 (diff)
Fix gaussianedge GM
Change-Id: Ia4523ea13992b325cb59f42e4458a199c7a98c4b Reviewed-on: https://skia-review.googlesource.com/10219 Commit-Queue: Robert Phillips <robertphillips@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/effects')
-rw-r--r--src/effects/SkGaussianEdgeShader.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/effects/SkGaussianEdgeShader.h b/src/effects/SkGaussianEdgeShader.h
new file mode 100644
index 0000000000..ef54ece56e
--- /dev/null
+++ b/src/effects/SkGaussianEdgeShader.h
@@ -0,0 +1,27 @@
+/*
+ * Copyright 2016 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef SkGaussianEdgeShader_DEFINED
+#define SkGaussianEdgeShader_DEFINED
+
+#include "SkShader.h"
+
+class SK_API SkGaussianEdgeShader {
+public:
+ /** Returns a shader that applies a Gaussian blur depending on distance to the edge
+ * Currently this is only useable with Circle and RRect shapes on the GPU backend.
+ * Raster will draw nothing.
+ */
+ static sk_sp<SkShader> Make();
+
+ SK_DECLARE_FLATTENABLE_REGISTRAR_GROUP()
+
+private:
+ SkGaussianEdgeShader(); // can't be instantiated
+};
+
+#endif