You have a bigger problem than your time delay issue. A lot of users
of your map will get the dreaded "Stalled Script" - IE especially. You
may have to consider switching to another strategy in order to restore
adequate response time. GPolygon objects (encoded or not) suffer from
the same problem as markers once a certain number are added. There are
a couple of solutions, some easier than others to implement. One
reasonably easy solution to implement is using image overlays instead
of GPolygons to solve the problem. They are fast, don't care how many
points make up the polygon and work in all browsers. Here's an example
of one such map:

http://maps.huge.info/zipcolors.htm

This example allows drawing of a polygon area (or radius around a
point) and then shows the zip codes that are in that area (US only).
The resulting map is a conglomeration of images that appear to be a
unified image. You could do something along these lines. This method
scales a lot better too.

The other alternative are tile based maps, they are much more complex
to implement though. Search this forum for more information on that
topic.

The drawback of using image based objects is the API can't monitor for
clicks within the polygon, that would have to be done on the server.
This can be considered a positive though, as the API is very poor at
handling polygon clicks. It consumes way too much of the client's
resources for very little gain. Even if you don't care about clicks
within a polygon, those resources are consumed anyway using the
GPolygon object.

-John Coryat

http://maps.huge.info

http://www.usnaviguide.com
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API" 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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to