Hello everyone , I'm new to openlayer and i have a problem and i need some help! I want to take the road network from an area and build a graph so i can take it and use it for finding sortest path . My problem is i don't know how to take the road network and how to construct the path . I done a google search and i found that i have to use OSM files but i don't know how . If you could show me some examples and point me to the right direction it would be great Thanks in advance, cheers john asked 21 Nov '11, 16:03 john_ |
You can extract road networks from OpenStreetMap data and use them for routing, but OpenLayers is only used to display the result of that process. Instead you'll need to get to know how OSM data is structured, the tools you can use to import it into other systems (such as pgRouting), how to perform routing queries, and only then how to display the results. If you have specific questions about OpenStreetMap you can ask them here, but otherwise a good place to start would be osm2pgrouting. answered 21 Nov '11, 16:20 Jonathan Ben... So i have to create a database and load my data there but is there anothere way to do that! I want to have my road network graph stored to a file so then i can run an algorithm to find the sortest path
(22 Nov '11, 15:29)
john_
pgRouting provides most common routing algorithms anyway, so you wouldn't need to reimplement them. Also, scanning a file to find start and end points of your route would be far more resource-intensive than using a database.
(22 Nov '11, 16:16)
Jonathan Ben...
To get an overview about all routing possibilities based on OSM, have a look at the wiki at http://wiki.openstreetmap.org/wiki/Routing and all its sub pages.
(22 Nov '11, 16:49)
stephan75
|