-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Always return a route #86
Comments
This is documented basically:
So I would like to reduce this requirement in general. |
I don't think that is a job for the library. It would then require more configuration, e.g. how far away is reasonable, if you have a small set of routes in Spain and click Greenland as a starting point and India as the end point, should it then still return a route? For my project I calculate them myself by having a threshold of 5km "off-road". So when clicking the map I calculate a bounding box with a 5km radius and then use that bounding box to test which road-segment's bounding box intersects. This just to make a quick calculation of possible candidates. If you have many roads you could segment them into larger bounding box groups. |
When the start or end point are not close enough to the graph there is no path results, or at least this is what I've seen in the demo page, I have yet to take this library for a spin.
It would be great if there was an option to return a route from the closest point on the graph to the start and end, this way, if you have a valid graph you will always have a path results.
Am I missing something in the docs?
Generally speaking, this is how graphhopper works and I think it's a good feature to always try and return a route.
The text was updated successfully, but these errors were encountered: