GIS / DEM (fwd)

Bill Brown brown at relay.cecer.army.mil
Fri Aug 16 08:00:00 EDT 1996



> Speaking of GIS and large scale stuff,
> 
> Does anyone have a DEM -> ElevationGrid converter?  If not, I'd like to
> try my hand at this converter-writin' game.  It looks to be pretty easy
> but I have not been able to figure out all the header stuff in the DEM
> files I have from USGS, and I was disappointed to find no entry for DEM in
> the O'Reilley graphics formats book.  It's also unfortunately the kind of
> thing that is very hard to find information on- all my searches were quite
> noisy.
> 
> Dan
> ___________________________________________________
> Dan Ancona     IATH-UVA, for now     (804) 982-4570
> http://jefferson.village.virginia.edu/~dfa4y
> 

Dan,

I'm in the process of writing a VRML export (or "paint" program in
GRASS speak) for GRASS data, but a DEM -> ElevationGrid converter
should be much simpler.   I think USGS has some example code you
could start with but if not I could send you some pieces from 
GRASS that read the USGS DEM files.  I don't think there's a
"standard" DEM format - the Digital Chart of the World DEMs are
different from the USGS 1 degree quads (although they are very
similar).  Rather, DEM is just a generic term (Digital 
Elevation Model) so the converter might have to be specific 
for a certain flavor.  

I'm pretty new to VRML, but it seems to me that since 
ElevationGrid doesn't allow for an embedded offset or translation
then we're going to lose the geographic reference information anyway
so all you're really interested in (besides the heights) is the 
xSpacing and zSpacing which would correspond to the e-w resolution 
and the n-s resolution of the DEM.  The resolutions are usually
the same. Also since ElevationGrid is a uniform grid, it probably 
doesn't make sense to try to correct lat-long data to try to 
approximate an equal area grid unless you want to do a scale of
one dimension based on the center latitude or something.

A question for the VRML spec folks:  It's nice to see the
set_height eventIn, but are there plans to also have a set_color
or set_texture?  In geographic modeling, it's much more common to
have a static terrain with changing surface attributes (water depth,
land use, vegetation, etc) than to have changing height.  Or is there
already another way to do this with VRML?

- Bill Brown
brown at gis.uiuc.edu
http://www.cecer.army.mil/grass/viz/VIZ.html







More information about the grass-user mailing list