Created
February 24, 2015 09:33
-
-
Save spatialhast/63677e0f0584a043caf3 to your computer and use it in GitHub Desktop.
UTGGrid & Vector Tiles
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Simple command line script to create UTFGrid json files from a polygon shapefile. | |
https://github.com/Ecotrust/create-utfgrids | |
Mapnik | |
# sudo apt-get install python-software-properties | |
# sudo add-apt-repository ppa:mapnik/nightly-2.3 | |
# sudo apt-get update | |
# sudo apt-get install libmapnik libmapnik-dev mapnik-utils python-mapnik | |
Python OGR | |
# sudo apt-get install python-gdal | |
cd /home/hast/create-utfgrids | |
./create_utfgrids.py -h | |
./create_utfgrids.py shpdata/kh_buildings_wgs3857.shp 14 18 /home/hast/create-utfgrids/utfgridtiles -f id | |
cp -R /home/hast/create-utfgrids/data/utfgrid.tiles /var/www/html/data | |
-------------------------------------------------------------------------------------------------------------------------- | |
-------------------------------------------------------------------------------------------------------------------------- | |
MMT-Vector-Tiles | |
A Tile-Vector generation library | |
https://github.com/glob3mobile/mmt-vector-tiles | |
Download latest release | |
https://github.com/glob3mobile/mmt-vector-tiles/releases | |
# sudo apt-get install oracle-java7-installer oracle-java7-set-default | |
# sudo dpkg --configure -a | |
# cd /home/hast/GIS/mmt-vector-tiles | |
# sudo ./run.sh parameters.xml | |
-------------------------------------------------------------------------------------------------------------------------- | |
-------------------------------------------------------------------------------------------------------------------------- | |
OSM geoJSON Tile Server on NodeJS | |
https://github.com/AnderPijoan/vectorosm | |
https://lists.openstreetmap.org/pipermail/dev/2013-July/027219.ht | |
# sudo apt-get install git | |
Install nodejs | |
# sudo apt-get update | |
# sudo apt-get install python-software-properties python g++ make | |
# sudo add-apt-repository ppa:chris-lea/node.js | |
# sudo apt-get update | |
# sudo apt-get install nodejs | |
# nodejs --version 0.10.33 | |
# mkdir osmdata && cd /home/hast/osmdata | |
# wget http://download.geofabrik.de/europe/kosovo-latest.osm.pbf | |
# osm2pgsql -m -s -c --drop -j -v --cache-strategy dense --flat-nodes tempFileErase -d osmkosovo -U hast -W -S /home/hast/osm2pgsql/default.style --number-processe 4 -C 4000 --hstore-add-index --exclude-invalid-polygon -r pbf /home/hast/osmdata/kosovo-latest.osm.pbf | |
# git clone https://github.com/AnderPijoan/vectorosm.git | |
# cd vectorosm | |
# sudo npm install express && sudo npm install pg && sudo npm install colors && sudo npm install body-parser | |
edit tileCreator.js | |
conString = 'tcp://postgres:postgres@localhost:5432/osm'; | |
# sudo node server.js | |
/generate/bbox/:zoom/:left/:top/:right/:bottom | |
http://localhost:8001/generate/bbox/16/21.13355/42.68046/21.17812/42.64715 | |
http://localhost:8001/generate/bbox/17/21.13355/42.68046/21.17812/42.64715 | |
http://localhost:8001/generate/bbox/18/21.13355/42.68046/21.17812/42.64715 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment