[Gdal-dev] PNG Heightfield

Matt Wilkie matt.wilkie at gov.yk.ca
Mon Mar 22 12:03:56 EST 2004


J Douglas Gough wrote:

> I would like to create a heightfield from an ArcInfo grid.  So far, I
> have successfully converted an elevation grid to a 16 bit grayscale PNG
> using gdal_translate.  I can see the difference in brightness
> correleates to height, but I'm stuck here.  I'm thinking I'll need to
> create a pallette and lookup table so there are 65,536 possible values.
> That should give me plenty of room to account for -5000 to +5000 meters
> or some other range that covers the min/max elevation in meters for any
> given point.  Just looking for some tips or examples.  

What program(s) are going to use the png-heightfield? Something like 
Virtual Terrain Project or World Construction Set can use them as-is 
where-is (there are probably others, these are just the ones I've used 
16bit images as DEMs with). If this for a program you are developing the 
source code for VTP should help.

cheers,

-- 
matt wilkie
--------------------------------------------
Geographic Information,
Information Management and Technology,
Yukon Department of Environment
10 Burns Road * Whitehorse, Yukon * Y1A 4Y9
867-667-8133 Tel * 867-393-7003 Fax
--------------------------------------------




More information about the Gdal-dev mailing list