Create a coverage-mask blur.
A blur is the only kind of mask filter Skia offers, so the first argument
is the blur style rather than a kind. Where MaskFilter.MakeBlur
returns null for a sigma Skia rejects, this throws instead.
ctx.maskFilter = new MaskFilter("outer", 6)
"normal" (both sides), "solid" (glow keeping the shape), "outer" (halo only), "inner" (inner shadow only)
blur standard deviation in pixels, greater than 0
OptionalrespectCTM: boolean
scale the blur with the canvas transform (default true); pass false to keep it screen-fixed
Mark filter as deleted. Use-after-delete throws Error.
StaticMakeGaussian coverage blur.
"normal" (both sides), "solid" (glow keeping the shape), "outer" (halo only), "inner" (inner shadow only)
blur standard deviation in pixels
OptionalrespectCTM: boolean
scale the blur with the canvas transform (default true); pass false to keep it screen-fixed
Coverage-mask filter (styled Gaussian blur). Unlike an
ImageFilterblur, theBlurStylecontrols how the blur relates to the geometry: glow, halo, inner shadow, feathered fill. Set on a context viactx.maskFilter. Mirrors CanvasKit'sMaskFilter.🧪 Not in the HTML Canvas standard.