This repository showcases the Microsoft's 9.8 million US buildings in Mapbox GL JS which is licensed under ODbL.
The dataset contains both building geometry and height information major cities in 44 US states. To visualise in Mapbox Studio, we converted the
Shapefiles -> GeoJSON -> MBTiles
.
All the state data were in shapefile format. This data needs conversion and cleanup to visualise better. There are the 3 steps to follow.
- Install ogr2ogr.
- Download and extract the compressed file.
- Use
ogr2ogr
to convert the shapefile to GeoJSON.
ogr2ogr -f GeoJSON -t_srs EPSG:4326 output.geojson input.shp
- Generate MBTiles using Tippecanoe,
tippecanoe -fo outout.mbtiles -l custom -z12 -Z12 state_name.geojson
- If you want to append all states GeoJSON to a single MBTiles use the
-F
option of Tippecanoe. Make sure you've given common output mbtiles and change the input GeoJSON file.
tippecanoe -Fo output.mbtiles -l custom -z12 -Z12 state_name.geojson
- Create Mapbox Studio account
- Upload the MBTiles in
Tilesets
section and visualise them.