garrettsickles / hgt2png

Convert SRTM HGT raster to a subset PNG rasters

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

hgt2png

Build Status

Convert HGT raster to a subset PNG rasters

Usage

Usage: 
        hgt2png <Mode> <HGT Source> <Output Prefix> <HGT Width> <HGT Height> [<Subwidth> <Subheight>]
Note:
        The last two parameters, [<Subwidth> <Subheight>], are optional.
            - If excluded, both default to 1.
            - If included, both must be counting number which evenly subdivide
                  <HGT Width> and <HGT Height>, respectively.

E.G.
        hgt2png a SOURCE.hgt temp/ 3601 3601 2 2

            => temp/SOURCE.0.0.png
            => temp/SOURCE.0.1800.png
            => temp/SOURCE.1800.0.png
            => temp/SOURCE.1800.1800.png

E.G.
        hgt2png r SOURCE.hgt MyData. 3601 3601

            => MyData.SOURCE.0.0.png

Example

Single Image

./hgt2png r N36W113.hgt test/ 3601 3601

Western Grand Canyon

Subdivided Images (n x n)

./hgt2png r N36W113.hgt test/ 3601 3601 3 3

Building

$ make clean
$ make

About

Convert SRTM HGT raster to a subset PNG rasters

License:Apache License 2.0


Languages

Language:C++ 98.6%Language:Makefile 1.4%