152 lines
5.0 KiB
ActionScript
152 lines
5.0 KiB
ActionScript
package com.common
|
|
{
|
|
import flash.filters.ColorMatrixFilter;
|
|
import flash.filters.GlowFilter;
|
|
|
|
public class PublicGlow
|
|
{
|
|
|
|
private static var instance:PublicGlow;
|
|
|
|
public var blackGlow:GlowFilter;
|
|
|
|
public var yellowGlow:GlowFilter;
|
|
|
|
public var yellowGlow1:GlowFilter;
|
|
|
|
public var yellowGlow2:GlowFilter;
|
|
|
|
public var greenGlow:GlowFilter;
|
|
|
|
public var huiGlow:GlowFilter;
|
|
|
|
public var qingGlow:GlowFilter;
|
|
|
|
public var lightFilter:ColorMatrixFilter;
|
|
|
|
public var menuFillter:GlowFilter;
|
|
|
|
public var greenGlow1:GlowFilter;
|
|
|
|
public var blackGlow1:GlowFilter;
|
|
|
|
public var textGlow:GlowFilter;
|
|
|
|
public function PublicGlow()
|
|
{
|
|
super();
|
|
this.blackGlow = new GlowFilter();
|
|
this.blackGlow.color = 0;
|
|
this.blackGlow.blurX = 2;
|
|
this.blackGlow.alpha = 1;
|
|
this.blackGlow.blurY = 2;
|
|
this.blackGlow.quality = 1;
|
|
this.blackGlow.inner = false;
|
|
this.blackGlow.knockout = false;
|
|
this.blackGlow.quality = 1;
|
|
this.blackGlow.strength = 4;
|
|
this.textGlow = new GlowFilter();
|
|
this.textGlow.color = 3350799;
|
|
this.textGlow.blurX = 2;
|
|
this.textGlow.alpha = 1;
|
|
this.textGlow.blurY = 2;
|
|
this.textGlow.quality = 1;
|
|
this.textGlow.inner = false;
|
|
this.textGlow.knockout = false;
|
|
this.textGlow.quality = 1;
|
|
this.textGlow.strength = 4;
|
|
this.blackGlow1 = new GlowFilter();
|
|
this.blackGlow1.color = 0;
|
|
this.blackGlow1.blurX = 2;
|
|
this.blackGlow1.alpha = 1;
|
|
this.blackGlow1.blurY = 2;
|
|
this.blackGlow1.inner = false;
|
|
this.blackGlow1.knockout = false;
|
|
this.blackGlow1.quality = 1;
|
|
this.blackGlow1.strength = 16;
|
|
this.huiGlow = new GlowFilter();
|
|
this.huiGlow.color = 1118481;
|
|
this.huiGlow.blurX = 2;
|
|
this.huiGlow.alpha = 1;
|
|
this.huiGlow.blurY = 2;
|
|
this.huiGlow.quality = 1;
|
|
this.huiGlow.inner = false;
|
|
this.huiGlow.knockout = false;
|
|
this.huiGlow.quality = 1;
|
|
this.huiGlow.strength = 6;
|
|
this.yellowGlow = new GlowFilter();
|
|
this.yellowGlow.color = 16776960;
|
|
this.yellowGlow.blurX = 10;
|
|
this.yellowGlow.alpha = 1;
|
|
this.yellowGlow.blurY = 10;
|
|
this.yellowGlow.inner = false;
|
|
this.yellowGlow.quality = 12;
|
|
this.yellowGlow.strength = 3;
|
|
this.yellowGlow1 = new GlowFilter();
|
|
this.yellowGlow1.color = 16776960;
|
|
this.yellowGlow1.blurX = 4;
|
|
this.yellowGlow1.alpha = 1;
|
|
this.yellowGlow1.blurY = 4;
|
|
this.yellowGlow1.inner = false;
|
|
this.yellowGlow1.quality = 6;
|
|
this.yellowGlow1.strength = 3;
|
|
this.menuFillter = new GlowFilter();
|
|
this.menuFillter.color = 16749361;
|
|
this.menuFillter.blurX = 4;
|
|
this.menuFillter.alpha = 1;
|
|
this.menuFillter.blurY = 4;
|
|
this.menuFillter.inner = false;
|
|
this.menuFillter.quality = 6;
|
|
this.menuFillter.strength = 3;
|
|
this.greenGlow = new GlowFilter();
|
|
this.greenGlow.color = 65280;
|
|
this.greenGlow.blurX = 15;
|
|
this.greenGlow.alpha = 1;
|
|
this.greenGlow.blurY = 15;
|
|
this.greenGlow.inner = true;
|
|
this.greenGlow.quality = 1;
|
|
this.greenGlow.strength = 1;
|
|
this.greenGlow1 = new GlowFilter();
|
|
this.greenGlow1.color = 65280;
|
|
this.greenGlow1.blurX = 4;
|
|
this.greenGlow1.alpha = 1;
|
|
this.greenGlow1.blurY = 4;
|
|
this.greenGlow1.inner = false;
|
|
this.greenGlow1.quality = 1;
|
|
this.greenGlow1.strength = 4;
|
|
this.qingGlow = new GlowFilter();
|
|
this.qingGlow.color = 57087;
|
|
this.qingGlow.blurX = 8;
|
|
this.qingGlow.alpha = 1;
|
|
this.qingGlow.blurY = 8;
|
|
this.qingGlow.inner = false;
|
|
this.qingGlow.quality = 1;
|
|
this.qingGlow.strength = 3;
|
|
this.yellowGlow2 = new GlowFilter();
|
|
this.yellowGlow2.color = 16776960;
|
|
this.yellowGlow2.blurX = 15;
|
|
this.yellowGlow2.alpha = 1;
|
|
this.yellowGlow2.blurY = 15;
|
|
this.yellowGlow2.inner = true;
|
|
this.yellowGlow2.quality = 2;
|
|
this.yellowGlow2.strength = 2;
|
|
this.lightFilter = this.createBrightnessFilter(65);
|
|
}
|
|
|
|
public static function getInstance() : PublicGlow
|
|
{
|
|
if(instance == null)
|
|
{
|
|
return instance = new PublicGlow();
|
|
}
|
|
return instance;
|
|
}
|
|
|
|
public function createBrightnessFilter(param1:Number) : ColorMatrixFilter
|
|
{
|
|
return new ColorMatrixFilter([1,0,0,0,param1,0,1,0,0,param1,0,0,1,0,param1,0,0,0,1,0]);
|
|
}
|
|
}
|
|
}
|
|
|