You can simplify polylines using the Ramer-Douglas-Peucker algorithm, which
discards vertices that are not needed for your zoom level.  The API does
this in the server for driving directions, and in the browser for other
polylines.

For efficiency the API will not draw offscreen polylines.

Are you generally concerned about latency or have you observed slow
performance on a mobile?

Ben

On 3 Apr 2010 10:07, "The Net Duck" <[email protected]> wrote:

HI
I would like to be able to do two things and I don't know if it's
possible with google maps api or if I need to build something myself.

thing 1)
  I would like to be able to "thin out" coordinates on a poly line
based on zoom level. This is because I don't need the amount of detail
when I'm zoomed out and am serving this as a mobile friendly site so
would like to use as little processes as possible.

thing 2)
  I have many different polylines (I call them routes), and would
like to only draw a polyline based on my maps "bounds". Is there a way
to only draw a line this way? or is this something that I need to do
by checking the coords that go into the creation of my polylines
agents some "bounds" objects etc.

Thanks so much!
- The Net Duck

--
You received this message because you are subscribed to the Google Groups
"Google Maps JavaScript API v3" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected]<google-maps-js-api-v3%[email protected]>
.
For more options, visit this group at
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" 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-js-api-v3?hl=en.

Reply via email to