Perl – Calculate distance between two points in an OpenStreetMap file

distanceopenstreetmapperl

I need to calculate the distance between two points in a map in the same way as Google Maps' distance matrix and get direction APIs.

Since I have to use offline more, I have to work with OpenStreetMap data.

I have downloaded the planet.osm file for the map data. How do I calculate the distance between two points with the OpenStreetMap file?

Best Answer

There are already several routing solutions for OpenStreetMap (OSM), including various web services, standalone programs, and libraries. You are probably interested in one of the many offline routers.

Related Topic