Index: include/effects/SkBlurMaskFilter.h |
diff --git a/include/effects/SkBlurMaskFilter.h b/include/effects/SkBlurMaskFilter.h |
index 356475ed4c47af3fdad513ebd2fb86e0a3db3a77..3ba91774f05b459f4afec83ccf09b438456b235e 100644 |
--- a/include/effects/SkBlurMaskFilter.h |
+++ b/include/effects/SkBlurMaskFilter.h |
@@ -37,7 +37,8 @@ public: |
* @param flags Flags to use - defaults to none |
* @return The new blur maskfilter |
*/ |
- static SkMaskFilter* Create(SkBlurStyle style, SkScalar sigma, uint32_t flags = kNone_BlurFlag); |
+ static sk_sp<SkMaskFilter> Make(SkBlurStyle style, SkScalar sigma, |
+ uint32_t flags = kNone_BlurFlag); |
/** Create an emboss maskfilter |
@param blurSigma standard deviation of the Gaussian blur to apply |
@@ -47,13 +48,22 @@ public: |
@param specular coefficient for specular highlights (e.g. 8) |
@return the emboss maskfilter |
*/ |
- static SkMaskFilter* CreateEmboss(SkScalar blurSigma, const SkScalar direction[3], |
- SkScalar ambient, SkScalar specular); |
+ static sk_sp<SkMaskFilter> MakeEmboss(SkScalar blurSigma, const SkScalar direction[3], |
+ SkScalar ambient, SkScalar specular); |
+#ifdef SK_SUPPORT_LEGACY_MASKFILTER_PTR |
+ static SkMaskFilter* Create(SkBlurStyle style, SkScalar sigma, uint32_t flags = kNone_BlurFlag){ |
+ return Make(style, sigma, flags).release(); |
+ } |
+ static SkMaskFilter* CreateEmboss(SkScalar blurSigma, const SkScalar direction[3], |
+ SkScalar ambient, SkScalar specular) { |
+ return MakeEmboss(blurSigma, direction, ambient, specular).release(); |
+ } |
SK_ATTR_DEPRECATED("use sigma version") |
static SkMaskFilter* CreateEmboss(const SkScalar direction[3], |
SkScalar ambient, SkScalar specular, |
SkScalar blurRadius); |
+#endif |
SK_DECLARE_FLATTENABLE_REGISTRAR_GROUP() |