Skip to content

Commit

Permalink
feat(basemaps): add tiling script (#373)
Browse files Browse the repository at this point in the history
  • Loading branch information
pwambach authored Jul 6, 2020
1 parent 9488c1b commit 995ecac
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions scripts/basemap-tiles.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/usr/bin/env bash

# Usage: ./basemap-tiles.sh <input-file> <output-folder>
# with Docker: docker run -v `pwd`:/data -w /data --name gdal2 -it --rm geographica/gdal2 ./basemap-tiles

# Images and worldfiles can be found here: https://drive.google.com/drive/folders/15UR1BBZRVPvLlvPF3s5yYNqpdmd6PMcF
# Upload tiles with: gsutil -m cp -r ./<output-folder>/ gs://esa-cfs-tiles/<version>/basemaps/<name>

input=$1
output=$2

gdal2tiles.py \
--profile geodetic \
--zoom=$ZOOM_LEVELS \
--tmscompatible \
--no-kml \
--webviewer=none \
--resampling average \
--s_srs EPSG:4326 \
$input \
$output

find $output -name '*.kml' -delete
find $output -name '*.aux.xml' -delete
find $output -name '*.json' -delete

0 comments on commit 995ecac

Please sign in to comment.