Last active
October 27, 2015 14:12
-
-
Save wknowles/9130299013894d8bf63d to your computer and use it in GitHub Desktop.
commands for a gdal workflow - in progress
This file contains hidden or 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
gdal_merge.py -init "255" -o combined.asc * | |
gdal_translate “-a_srs EPSG:4326” -co COMPRESS=LZW -stats combined.asc combined.tif | |
gdal_translate -co COMPRESS=LZW -stats combined.asc combined.tif | |
gdaldem hillshade -compute_edges -co compress=lzw combined.tif hillshade.tif | |
—-- | |
gdalinfo -stats combined.tif #to find height info - this will affect ramp.txt | |
gdaldem color-relief -co COMPRESS=LZW combined.tif ramp.txt output-color-relief.tif | |
—-- | |
gdaldem slope -co compress=lzw combined.tif combined-slope.tif | |
gdaldem color-relief -co compress=lzw combined-slope.tif slope-ramp.txt output-slope-shade.tif | |
#builds image pyramids/overviews | |
gdaladdo -r average output-slope-shade.tif 2 4 8 16 | |
#removes geo information | |
convert -gamma .5 output-slope-shade.tif output-slope-shade-gamma.tif | |
--- | |
gdal_contour -i 0.5 -a height combined-slope-shade.tiff outshapefile.shp | |
ogr2ogr -f GeoJSON shape.geojson outshapefile.shp | |
--- | |
convert output-color-relief.tif hills_gamma.tif -compose Overlay -composite output.tif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment