Reputation: 558
I'm building a web app that makes use of the Google Maps API and have run across a small math problem.
I have a center point in lat/lng and an area in kilometres. How would I calculate the NE and SW lat/lng points for a bounding box? Thanks.
Upvotes: 1
Views: 879
Reputation: 22943
Consider using methods of Projection class http://code.google.com/apis/maps/documentation/javascript/reference.html#Projection to convert values from latang format to km and back.
I can suggest the following algo:
Upvotes: 1