I would use two layers, a _bgTexture
with just the texture as you have, and a _bgShading
with some greyscale lighting above that based on your original, but with a blendMode
of BlendMode.OVERLAY
, then expand the radial gradient a bit to avoid the sharp edges and add an inner shadow.
Just testing in the Flash IDE, I've used COLORS:Array = [0xDDDDDD, 0x777777]
, the texture exported as a BackgroundTexture
class, and the following method based off your updateDisplayList
to get this:
function drawBG(unscaledWidth:Number, unscaledHeight:Number):void {
_bgShading.graphics.clear();
_matrix.createGradientBox(unscaledWidth * 1.2, unscaledHeight * 2.2, 0, -unscaledWidth * 0.1, -unscaledHeight * 0.8);
_bgShading.graphics.beginGradientFill(GradientType.RADIAL,
COLORS,
ALPHAS,
RATIOS,
_matrix,
SpreadMethod.PAD,
InterpolationMethod.LINEAR_RGB,
0);
_bgShading.graphics.drawRect(0, 0, unscaledWidth, unscaledHeight);
_bgShading.graphics.endFill();
_bgShading.filters = [new DropShadowFilter(0, 0, 0x000000, 1.0, 10.0, 10.0, 1.0, 3, true)];
_bgTexture.graphics.clear();
_bgTexture.graphics.beginBitmapFill(new BackgroundTexture());
_bgTexture.graphics.drawRect(0, 0, unscaledWidth, unscaledHeight);
_bgTexture.graphics.endFill();
_bgShading.blendMode = BlendMode.OVERLAY;
}