Package | starling.filters |
Class | public class CompositeFilter |
Inheritance | CompositeFilter FragmentFilter EventDispatcher Object |
Method | Defined By | ||
---|---|---|---|
Creates a new instance. | CompositeFilter | ||
addEventListener(type:String, listener:Function):void Registers an event listener at a certain object. | EventDispatcher | ||
cache():void Caches the filter output into a texture. | FragmentFilter | ||
clearCache():void Clears the cached output of the filter. | FragmentFilter | ||
dispatchEvent(event:Event):void Dispatches an event to all objects that have registered listeners for its type. | EventDispatcher | ||
dispatchEventWith(type:String, bubbles:Boolean = false, data:Object = null):void Dispatches an event with the given parameters to all objects that have registered
listeners for the given type. | EventDispatcher | ||
dispose():void Disposes all resources that have been created by the filter. | FragmentFilter | ||
getAlphaAt(layerID:int):Number Indicates the alpha value with which the layer is drawn. | CompositeFilter | ||
getColorAt(layerID:int):uint Returns the RGB color with which a layer is tinted when it is being drawn. | CompositeFilter | ||
getOffsetAt(layerID:int, out:Point = null):Point Returns the position (in points) at which a certain layer will be drawn. | CompositeFilter | ||
hasEventListener(type:String, listener:Function = null):Boolean If called with one argument, figures out if there are any listeners registered for
the given event type. | EventDispatcher | ||
process(painter:Painter, helper:IFilterHelper, input0:Texture = null, input1:Texture = null, input2:Texture = null, input3:Texture = null):Texture [override] Combines up to four input textures into one new texture,
adhering to the properties of each layer. | CompositeFilter | ||
removeEventListener(type:String, listener:Function):void Removes an event listener from the object. | EventDispatcher | ||
removeEventListeners(type:String = null):void Removes all event listeners with a certain type, or all of them if type is null. | EventDispatcher | ||
Renders the filtered target object. | FragmentFilter | ||
setAlphaAt(layerID:int, alpha:Number):void Adjusts the alpha value with which the layer is drawn. | CompositeFilter | ||
setColorAt(layerID:int, color:uint, replace:Boolean = false):void Adjusts the RGB color with which a layer is tinted when it is being drawn. | CompositeFilter | ||
setOffsetAt(layerID:int, x:Number, y:Number):void Indicates the position (in points) at which a certain layer will be drawn. | CompositeFilter |
CompositeFilter | () | Constructor |
public function CompositeFilter()
Creates a new instance.
getAlphaAt | () | method |
public function getAlphaAt(layerID:int):Number
Indicates the alpha value with which the layer is drawn.
Parameters
layerID:int |
Number |
getColorAt | () | method |
public function getColorAt(layerID:int):uint
Returns the RGB color with which a layer is tinted when it is being drawn.
Parameters
layerID:int |
uint |
getOffsetAt | () | method |
public function getOffsetAt(layerID:int, out:Point = null):Point
Returns the position (in points) at which a certain layer will be drawn.
Parameters
layerID:int | |
out:Point (default = null )
|
Point |
process | () | method |
override public function process(painter:Painter, helper:IFilterHelper, input0:Texture = null, input1:Texture = null, input2:Texture = null, input3:Texture = null):Texture
Combines up to four input textures into one new texture, adhering to the properties of each layer.
Parameters
painter:Painter | |
helper:IFilterHelper | |
input0:Texture (default = null )
| |
input1:Texture (default = null )
| |
input2:Texture (default = null )
| |
input3:Texture (default = null )
|
Texture |
setAlphaAt | () | method |
public function setAlphaAt(layerID:int, alpha:Number):void
Adjusts the alpha value with which the layer is drawn.
Parameters
layerID:int | |
alpha:Number |
setColorAt | () | method |
public function setColorAt(layerID:int, color:uint, replace:Boolean = false):void
Adjusts the RGB color with which a layer is tinted when it is being drawn.
If replace
is enabled, the pixels are not tinted, but instead
the RGB channels will replace the texture's color entirely.
Parameters
layerID:int | |
color:uint | |
replace:Boolean (default = false )
|
setOffsetAt | () | method |
public function setOffsetAt(layerID:int, x:Number, y:Number):void
Indicates the position (in points) at which a certain layer will be drawn.
Parameters
layerID:int | |
x:Number | |
y:Number |