Graphics Programs Reference
In-Depth Information
FIGurE 8-41 Plain map with Microsoft road map
P You can also
use your own
tiles if you want.
There's a good
tutorial on the
Modest Maps
site.
P See the Adobe
reference for more
on how to use col-
or matrices to cus-
tomize objects in
ActionScript at
http://livedocs
.adobe.com/flash/
9.0/ActionScript
LangRefV3/flash/
filters/Color
MatrixFilter
.html .
FIGurE 8-42 Plain map with Yahoo! hybrid map
You can also experiment with the colors of the map by applying filters.
You could for example, change the map to grayscale by placing the follow-
ing under the code you just wrote. The mat array is of length 20 and takes
values from 0 to 1. each value represents how much red, green, blue and
alpha each pixel gets.
var mat:Array = [0.24688,0.48752,0.0656,0,44.7,0.24688,0.48752,
0.0656,0,44.7,0.24688,0.48752,0.0656,0,44.7,0,0,0,1,0];
var colorMat:ColorMatrixFilter = new ColorMatrixFilter(mat);
map.grid.filters = [colorMat];
Search WWH ::




Custom Search