A module to use Itinero together with NTS and IO from common geo formats. The following projects can be found in this repo:
- Itinero.Geo: Links Itinero and NTS together.
- Itinero.IO.Shape: IO to read/write routable shapefiles.
The biggest usecase is to load shapefiles into Itinero:
// the vehicle profile defines the from and to columns and things like speeds per link type.
var vehicle = DynamicVehicle.LoadFromStream(File.OpenRead("car.lua")); // load data for the car profile.
// create a new router db and load the shapefile.
var routerDb = new RouterDb(EdgeDataSerializer.MAX_DISTANCE);
routerDb.LoadFromShape("/path/to/shape/", "wegvakken.shp", vehicle);
// write the router db to disk for later use.
routerDb.Serialize(File.OpenWrite("nwb.routerdb"));
More info is in the sample in this repo.