a-b-street / osm2streets

Convert OSM to street networks with detailed geometry
https://a-b-street.github.io/osm2streets
Apache License 2.0
101 stars 9 forks source link

Replace `country-geocoder` with `country-boundaries` #269

Closed JamesHinshelwood closed 3 months ago

JamesHinshelwood commented 3 months ago

Instead of relying on country-geocoder to find a country code, we now use country-boundaries. This makes the lookup faster, but more importantly it also returns correct results for regions and countries which are not admin_level=0, such as Hong Kong or Macau.

country-boundaries does not include data on whether a country drives on the left or right, however thankfully muv-osm does, so we use its data instead (which is generated from wikidata.org).

Fixes #267

Example: https://a-b-street.github.io/osm2streets/#18.47/22.3022565/114.0112691

Before image

After image