Frames collection which you can apply bitmap filters to. WARNING: this frame collection doesn't use caching, so be careful or you will "leak" out memory very fast. You should destroy frames collections of this type manually.
Static methods
staticinlinefromFrames(frames:FlxFramesCollection, widthInc:Int = 0, heightInc:Int = 0, ?filters:Array<BitmapFilter>):FlxFilterFrames
Generates new frames collection from specified frames.
Parameters:
frames | Frames collection to generate filters for. |
---|---|
widthInc | How much frames should expand horizontally. |
heightInc | How much frames should expend vertically. |
filters | Optional filters array to apply. |
Returns:
New frames collection which you can apply filters to.
Variables
Methods
inlineaddFilter(filter:BitmapFilter):Void
Adds a filter to this frames collection.
Parameters:
filter | The filter to be added. |
---|
applyToSprite(spr:FlxSprite, saveAnimations:Bool = false, updateFrames:Bool = false):Void
Just helper method which "centers" sprite offsets
Parameters:
spr | Sprite to apply this frame collection. |
---|---|
saveAnimations | Whether to save sprite's animations or not. |
updateFrames | Whether to regenerate frame |
removeFilter(filter:BitmapFilter):Void
Removes a filter from this frames collection.
Parameters:
filter | The filter to be removed. |
---|