I'd like to use Google maps static API to display a map with a path overlay indicating a boundary.
AFAICT the static API doesn't support polygons, so I intend to circumvent this by drawing the boundary using paths.
To do this I need to determine the points to draw the straight lines (paths) between; so I'd like an algorithm that returns the geographic location (i.e. WGS84 coordinates) a given bearing and distance from a known point.
Can anyone point me to such an algorithm. Preferably in C#, but other languages are acceptable?
I implemented and tested it in C#, using Degrees as input/output instead of radians:
You can draw polygon on a KML file, and then show the KML on Google maps.
Here's KML on Google maps (From Google KML Samples) check the "Google Campus - Polygons" section in the content.
Found this (here: http://williams.best.vwh.net/avform.htm#LL):
A point {lat,lon} is a distance d out on the tc radial from point 1 if:
Will the radial be in radians or degrees?
Edit:
radians = degrees * PI / 180
Take a look at Gavaghan Geodesy C# library, it should be what you're looking for. And it's free.
In (I think) every language I know, radians. Note that I think your example code is giving you co-ordinates based on a sphere, not on WGS84. Here's Java code for converting between co-ordinate systems.