valhalla / valhalla/valhalla

avoid specific country borders

Open
#4,142 2 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
C++
Stars
6.2k
Forks
981
Avg merge
2d 14h
Merged PRs (30d)
14

Description

While reading https://github.com/valhalla/valhalla/discussions/4141, first mis-read and thought the question was about avoiding certain borders, not tolls in certain countries. While the latter is also appealing, I thought I'd still open an issue for the former.

Often one wants to avoid certain country borders only, e.g. in Europe outside Schengen (and still cross borders within). I didn't think too hard about it yet, just general design suggestion:

Having an array of arrays for country-pairs to avoid like `"avoid_country_borders": [["DE", "DK"], ["DE", "NL"]]` and have that info passed to the costing and when an edge crosses countries, we look at both nodes' country index? Bit of a penalty with another if branch..

~~Can we resolve admin indices to their ISO 2 codes?~~ sure we can, via the tile's admin info

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.