perliedman / geojson-path-finder

Find shortest path through a network of GeoJSON
https://www.liedman.net/geojson-path-finder/
ISC License
300 stars 86 forks source link

Is it possible to add a 'level' info? #57

Open lmdc45 opened 4 years ago

lmdc45 commented 4 years ago

for instance I would have

At this stage I got small issues with some path going from under the bridge straight to the bridge, as lines are crossing...

I am trying to eliminate common/near vertexes on these locations as a way to solve it, however was wondering if it would be possible another way.

Thanks

perliedman commented 4 years ago

Hi, it would definitely be interesting to incorporate something like this, but at the moment there is no support: all vertices that are sufficiently close will be considered as a node in the graph.

I think changing this would only need to affect the topology.js function, which is responsible for turning the LineStrings into nodes and edges.

lmdc45 commented 4 years ago

Ok thanks. I am not an expert so will try not to touch topology.js. I will try to work on the geojson data first, to avoid close nodes in intersection if different levels.

lmdc45 commented 4 years ago

In fact this seems quite similar to issue #25 , will look at adding z coords