GlowFilter class

A filter that applies a glow effect to an object. This filter is similar to a GDropShadowFilter with a BlurStyle.outer MaskFilter applied.

Inheritance
Available Extensions

Constructors

GlowFilter([double blurX = 0, double blurY = 0, Color color = kColorRed, bool hideObject = false])
Creates a new instance of GlowFilter.

Properties

blurX double
The blur value for the filter on the x-axis.
getter/setter pair
blurY double
The blur value for the filter on the y-axis.
getter/setter pair
color Color
The color value for the filter.
getter/setter pair
currentObject GDisplayObject?
The currentObject property holds a reference to the display object that the filter is applied to. OutlineFilter uses this to adjust the filter size to the current object scale.
getter/setter pairinherited
dirty bool
The dirty property is used to determine if the filter needs to be rebuilt.
getter/setter pairinherited
filterRect GRect
Returns the filter rectangle bounding area.
no setter
hashCode int
The hash code for this object.
no setterinherited
hideObject bool
Whether to hide the content behind the filter.
getter/setter pairinherited
isValid bool
(Internal usage) Checks if the filter is valid and should be applied.
no setteroverride
iterations int
Number of iterations to apply the same filter. Bigger value, value more stressed.
getter/setter pair
layerBounds GRect?
The layerBounds property holds the bounds of the display object.
getter/setter pairinherited
maskSigma double
The mask sigma value for the filter.
getter/setter pair
paint Paint
The paint object used to apply the painting function.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
style BlurStyle
The blur style of the filter.
getter/setter pair

Methods

buildFilter() → void
(Internal usage) Constructs and sets the filters used by this GlowFilter.
override
expandBounds(GRect layerBounds, GRect outputBounds) → void
Expands the layerBounds by blurX * 2 and blurY * 2 and copies the result to the bounds rect. Then expands the outputBounds to include _rect
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
process(Canvas? canvas, Function applyPaint, [int processCount = 1]) → void
Applies the glow filter to the canvas using the applyPaint function, with the given number of iterations. Each iteration applies the same filter, resulting in a stronger effect.
override
resolvePaint(Paint paint) → void
Applies the filter effect to the specified paint object.
inherited
toString() String
A string representation of this object.
inherited
update() → void
The update method is called to check if the filter needs to be rebuilt. If the dirty property is true and the isValid property is also true, then the buildFilter method is called to rebuild the filter.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited