On Sep 15, 7:29 am, Paul Kulchenko <paulclin...@gmail.com> wrote:

> I also switched to using my own calculations for the Mercator
> projection and it seems to be almost 5 times faster than gmap's
> fromLatLngToPixel(). I didn't expect such a significant difference (on
> 1000+ points). Although there may be other factors in play that I
> haven't excluded (I haven't tried the simplest possible example just
> to benchmark it).

Yep.  Virtually all Google maps are Mercator but "fromLatLngToPixel()"
has to be able to handle other oddball projections.  It also requires
a "new GLatLng()" object for every call which just adds overhead.  V3
does not even provide a "fromLatLngToPixel()" method.  V3 does provide
a "fromLatLngToDivPixel()" method but for tile numbers, you must roll
your own.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API" group.
To post to this group, send email to google-maps-api@googlegroups.com
To unsubscribe from this group, send email to 
google-maps-api+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-maps-api?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to