GComposerFilter class abstract
A base class for filters that modify the appearance of content.
This class defines a common interface for all filters, including the ability
to expand the bounds of the filtered content, check whether the filter has
any effect, and resolve the paint object used to apply the filter to the
content.
This filter can be used to apply a painting function to a canvas and blend
the resulting content with other content layers using the Canvas.saveLayer
and Canvas.restore
methods. The filter can be configured to hide the
content behind it by setting the hideObject
property to true
.
- Inheritance
-
- Object
- GBaseFilter
- GComposerFilter
- Implementers
Constructors
Properties
- 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
- hashCode → int
-
The hash code for this object.
no setterinherited
- hideObject ↔ bool
-
Whether to hide the content behind the filter.
getter/setter pair
- isValid → bool
-
The isValid property determines if the filter is valid and can be
applied.
no setterinherited
- layerBounds ↔ GRect?
-
The layerBounds property holds the bounds of the display object.
getter/setter pairinherited
- paint → Paint
-
The paint object used to apply the painting function.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
buildFilter(
) → void -
The buildFilter method is called to rebuild the filter.
inherited
-
expandBounds(
GRect layerBounds, GRect outputBounds) → void -
The expandBounds method is used to expand the bounds of the display object.
The
layerBounds
parameter is the current bounds of the display object, and theoutputBounds
parameter is the bounds that should be expanded to.inherited -
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 painting function to the specified canvas and blends the resulting content with other content layers using the Canvas.saveLayer and Canvas.restore methods in subclasses.
-
resolvePaint(
Paint paint) → void -
Applies the filter effect to the specified paint object.
override
-
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