FlattenFilter class
The FlattenFilter does not change the visual appearance of the BitmapData or DisplayObject where it is applied to. This filter can be used to merge the children of a DisplayObjectContainer to a flat texture. This is useful for DisplayObjects with certain blend modes or alpha values.
Example:
var sprite = new Sprite();
sprite.addChild(background);
sprite.addChild(foreground);
sprite.addChild(text);
sprite.blendMode = BlendMode.ADD;
sprite.filters = [FlattenFilter()];
- Inheritance
-
- Object
- RenderFilter
- BitmapFilter
- FlattenFilter
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- isSimple → bool
-
no setterinherited
-
overlap
→ Rectangle<
int> -
no setterinherited
-
renderPassSources
→ List<
int> -
no setterinherited
-
renderPassTargets
→ List<
int> -
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
apply(
BitmapData bitmapData, [Rectangle< num> ? rectangle]) → void -
inherited
-
clone(
) → BitmapFilter -
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
renderFilter(
RenderState renderState, RenderTextureQuad renderTextureQuad, int pass) → void -
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited