GEOL 6325 [link outdated]
Remote Sensing Final Project
May 5, 2004
B.J. Guillot


Create a 3D viewer for DEM data with overlay capability for Landsat data.


Use the data provided in the Remote Sensing Lab 8 [link outdated] as the primary data source for the viewer program.

Verify "correctness" by comparing 2D images with ENVI Freelook. This is a very limited, but free version of ENVI available for download. See [link outdated] or [link outdated] for more information.

Develop code using the C programming language and use OpenGL for graphics. The C compiler was a free download from Microsoft, included with the .NET SDK (Software Development Kit).

Area of Interest:
Big Pine: Owens Valley California

Map obtained from [link outdated]
Alternate location at

Landsat image (acquired 7/7/1984) as viewed from ENVI using a 3-2-1 band combination:

Description of Landsat image:
This Landsat image shows Owens Valley of eastern California. The town of Big Pine is located to the north of Crater Mountain, the large brownish feature near the center of the image. "The rugged crest of the Sierra Nevada Mountains flanks the valley on the southwest, and the Inyo Mountains lie along the eastern edge. This is a desert landscape with only sparse natural vegetation; some irrigated cropland is found near the Owens River. The scene principally illustrates geologic features, such as the glacially-sculpted Sierra crest (with partial snow cover) and broad alluvial fans stretching eastward from the mountain front. Recent basalt lava flows and cinder cones (dark gray to red tones) cover parts of the down-faulted Owens valley. The large cinder cone just south of Big Pine (Crater Mountain) is cut by two fault scarps visible as dark lines or color changes. The western fault line stretches southward (marked on its upslope side by patches of dark green vegetation) to the smaller cinder cone Red Mountain at the center of the scene." [1].

Program Features:

Ability to display Landsat images as a 2D RGB plane.

Landsat data is displayed with 2% linear stretch.

Ability to convert Landsat image to 3D using DEM data.

Ability to switch between 2D and 3D on-the-fly.

Ability to change Landsat band combinations on-the-fly.

Ability to change resolutions on-the-fly (decimation to speed up rendering).

Rotation, Translation, and Scaling (Zooming) of 2D and 3D images.


The series of DEM points need to be converted to a surface consisting of polygons in order to be rendered by the graphics card. This was done by taking four adjacent points and joining them together into a quad.

The program initially did not offer the 2% linear stretch and the images looked very poor.

It took me quite a while to code the stretch to produce images as nice as ENVI. I had to compute a histogram internally, shave off 2% on each end, and then "rescale" the remaining 96% of the data over the full 8-bit color range.

Screen Shots:

Big Pine: 2D Landsat 3-2-1 image

Big Pine: 3D DEM with Landsat 3-2-1 overlay

Big Pine: 2D Landsat 4-3-2 image

Big Pine: 3D DEM with Landsat 4-3-2 overlay

Big Pine: 3D DEM with Landsat 4-3-2, zoomed in

Here is a screenshot of 3D viewer someone else wrote of the same area [1].

Project Source Code:

Source Code

Program Limitations:

Currently "hardwired" for the Lab 8 data. It expects the DEM data to be exactly 1123x940 pixels (dem.bil).

My testing has been with the unwarped Landsat data from Lab 8, and it the program is hardwired to read in the 1278x819 pixels (big_pine.bsq).

Future Work:

Remove the limitations previously discussed.

Add support for mouse control of rotations, translations, and zooms.

Add support for lighting light defition and smooth shading to simulate sunshine.

Add control over vertical exaggeration.

Add support for band ratios.

Clean up the source code, and potentially convert to another language in order to allow the 3D models to be manipulated using the web. A logical choice for this might be to generate models in VRML (virtual reality modeling language) and use a client-side browser for image manipulating. An example VRML client can be downloaded from Cortona, and example VRML images can be obtained from the following sites once you have installed the Cortona plug-in:
3D Virtual Garden [link outdated]
3D Human Body


[1] Microimages.

[2] Woo, Mason. OpenGL Programming Guide. Second Edition. 1997.

B.J. Guillot