On Feb 26, 6:17 am, canada77 <[email protected]> wrote: > I am new to Google Maps and have been learning it quite nicely, but > still can't seem to find the answer to 2 questions: > > 1) I have a very large polyLine (13,000 vertexes) that has been > constructed from driving directions. I want to overlay an image at > specific vertexes along the polyLine, but do not want to overlay the > images that are not currently visible (causes considerable slowdown). > How can I determine, based on the current map view, which vertexes of > the polyLine are currently visible? I can then add the GroundOverlay > at only the visible vertexes.
This is a classic case for something like a Marker Manager. Have you tried adding your overlays to a marker manager? (Note: I have no idea whether either GMarkerManager or the open-source version can cope with anything other than markers, but it's worth a try) http://code.google.com/apis/maps/documentation/reference.html#GMarkerManager http://gmaps-utility-library.googlecode.com/svn/trunk/markermanager/release/ If not, then you will have to implement your own manager which keeps track of the visible bounds [or possibly visible+buffer] and adds and removes overlays as required by moves, pans, drags and zooms. Andrew --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
