DropShadowFilter Demo
package
{
import flash.display.Sprite;
import flash.filters.DropShadowFilter;
import flash.filters.GlowFilter;
public class SpriteOverlay extends Sprite
{
private var circleA:Sprite = new Sprite();
private var circleB:Sprite = new Sprite();
public function SpriteOverlay()
{
circleA.graphics.beginFill(0x00ff00, 1);
circleA.graphics.drawCircle(0, 0, 15);
circleA.graphics.endFill();
circleB.graphics.beginFill(0x00ff00, 1);
circleB.graphics.drawCircle(0, 0, 15);
circleB.graphics.endFill();
circleA.filters = [new DropShadowFilter(100),
new GlowFilter(0xFF0000, .5, 100, 100)];
circleB.filters = [new DropShadowFilter(100)];
var circleGlow:Sprite = new Sprite();
circleGlow.addChild(circleA);
circleGlow.addChild(circleB);
circleGlow.y = 100;
addChild(circleGlow);
circleGlow.filters = [new GlowFilter(0xFF0000, .5, 100, 100)];
}
}
}
Related examples in the same category