Collection of bash scripts to inspect and reproject coordinates, bounding boxes and WKT strings.
Most scripts allow to pass the input geometry (bbox, coordinate or wkt string) to be passed on standard input. When passing geometry on standard input replace the input geometry argument with -.
Requires libproj-dev, gdal-bin and perl to be installed.
Add directory to PATH (add to .bashrc or .zshrc):
export PATH=${geobash_installation_path}:$PATHSource files are linted with Shellcheck.
Create GPKG with geometries of all tiles of zoomlevel 3 (nr of tiles per zoomlevel is 2^z, zoomlevel z is zero-based index) of Dutch tiling scheme (EPSG:28992):
zxy2bbox 28992 4/{0..15}/{0..15} | bbox2wkt | wkt2ogr - 28992 GPKG grid.gpkg gridShow tile boundaries of specific tile (Dutch tiling scheme; EPSG:28992):
zxy2bbox 28992 2/2/1 | bboxproj 28992 4326 - | bboxshowCalculate scale denominator of WMS GetMap request:
wmsmap2scaledenominator https://service.pdok.nl/hwh/luchtfotorgb/wms/v1_0?SERVICE=WMS&REQUEST=GetMap&VERSION=1.3.0&LAYERS=Actueel_ortho25&BBOX=233328.32,554123.2,233382.08,554176.96&WIDTH=256&HEIGHT=256&CRS=EPSG:28992&FORMAT=image/png