Friday, December 19, 2008

Simple way to Draw a Circle with Google Maps

The Google Maps API doesn't provide a "draw circle" function for free, so you're left to your own devices to draw an approximation of a circle using the GPolyline object.

Here's a really basic circle drawing example adapted from the more complex example below. My simple example:

http://www.herculessolutions.com/GoogleMapsSimpleCircle.htm

The more complex example with dragable points and more:

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

5 comments:

Stephane said...

Other interesting tool: http://dev.bt23.org/keyhole/circlegen/

Anonymous said...

Hi Jeremy, your drawing script works a treat. Do I have your permission to embed it in my Web page?

Unknown said...

so how do i do the first red circle

Stephane said...

The last tool I mentionned doesn't work correctly anymore: use http://www.thesamestory.com/kmlcircle/

mnar said...

Hi, I have a bug with firefox when I try to draw a circle around "North pole" (probably an infinite loop).