How to find every point [ coordinates ] between tw

2019-06-08 20:52发布

问题:

Leaflet map

How i get geo-coordinates( i.e latitude,longitude ) on every 1km/2km/(n)Km between two geolocation points. Image above for reference.

回答1:

The "right way" to do this is to use geographiclib to fetch the azimuth and angular distance between the points; then fetch intermediate points by keeping the azimuth but specifying a different angular distance.

Geographiclib is also able to calculate a point given an initial point, an azimuth, and a distance in meters.

I suggest you first do a bit of research on what a "great circle" is, as well as the direct and inverse geodetic problems.