I'm building my own routing engine - which means I'm not using any of the routing frameworks for OSM.

So far I've built a graph with edges and vertices.

I'm parsing all the ways that are highways (I'm not taking areas).

My question is: how can turn a way into an edge (with one only two nodes, one defining the start and one defining the end) and remove all the ones in the middle? What approach has developers taken with this problem?

Thank you

asked 06 Feb '15, 15:23

echoalphapapa's gravatar image

echoalphapapa
417812
accept rate: 0%

edited 06 Feb '15, 15:45

aseerel4c26's gravatar image

aseerel4c26 ♦
31.9k16237548


You could of course have a look at the existing routing engines which you don't want to use, each of which have solved that problem in one way or the other.

The question that you have been linked to in the post you reference above actually contains the answer. Re-read it: How can I convert an OSM XML file into a graph representation?

permanent link

answered 06 Feb '15, 15:46

Frederik%20Ramm's gravatar image

Frederik Ramm ♦
69.9k806321095
accept rate: 24%

edited 06 Feb '15, 15:48

I was looking for an explanation that's a bit more low level.

(06 Feb '15, 15:59) echoalphapapa

Can you be more specific? Which parts are unclear to you? Where are you stuck?

(06 Feb '15, 17:06) scai ♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×249
×108
×16
×16

question asked: 06 Feb '15, 15:23

question was seen: 2,777 times

last updated: 06 Feb '15, 17:06

powered by OSQA