Hi Peter-
Re 1) Just go for it and see what problems you run into. I'd start with the
marker categories demo, include the CustomIconSprite.as in my project, and
then pass the custom icon into the MarkerOptions.
Re 2) I haven't got the code for this online yet, but we did do this for the
Victoria Bushfires map, using differently sized circles and labels to
represent number of fires. Here's the code:
var sprite:Sprite = new Sprite();
sprite.graphics.lineStyle(2, 0x000000, 1);
sprite.graphics.beginFill(color, 1);
sprite.graphics.drawCircle(0,0,radius);
if (label != "") {
var labelMc = new TextField();
labelMc.autoSize = TextFieldAutoSize.LEFT;
labelMc.selectable = false;
labelMc.border = false;
labelMc.embedFonts = false;
labelMc.mouseEnabled = false;
labelMc.width = radius;
labelMc.height = radius;
labelMc.text = label;
labelMc.x = -(labelMc.width * 0.5);
labelMc.y = -(labelMc.height * 0.5);
sprite.addChild(labelMc);
}
var marker:Marker = new Marker(latlng, new MarkerOptions({icon: sprite,
tooltip: title, hasShadow: false}));
Re 3) There is no strict and hard limit, but you can run into performance
issues. General solutions are using MarkerManager with some sort of
clustering.
- pamela
On Mon, Mar 23, 2009 at 3:17 AM, Pete <[email protected]> wrote:
>
> Hi,
> I've got a few questions related to custom markers. I'm digging around
> for answers and experimenting a lot, but will post here in the
> meantime.
>
> I'm new to programming and am tackling my first Flex application for a
> data visualization project dealing with about 4,000 worldwide
> addresses (geocoded and in XML), and need to toggle between at least 4
> categories (by type). I've mostly been referring to Pamela's "Custom
> Icon Sprite" and "Toggling Marker Categories".
> So here's what I'm wondering:
>
> (1) How can I essentially combine these demos, to toggle between four+
> custom icon sprites?
>
> (2) Is it possible to animate the sizes of custom marker sprites to
> reflect related data (i.e., greater value associated with an address =
> larger shape)? (And can anyone point to a demo or example?)
>
> (3) Is there a maximum number of markers that can be displayed at a
> given zoom level? I've been unable to display more than a small
> portion of addresses at a time and want to display all (or as many as
> possible) from lower zoom levels. Is the multi-level MarkerManager the
> way to do this?
>
> Thanks,
> Peter
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API For Flash" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-maps-api-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---