Mapping Images onto Surfaces Overview

Mapping an image onto geometry, also known as texture mapping, involves overlaying an image or function onto a geometric surface. Images may be realistic, such as satellite images, or representational, such as color-coded functions of temperature or elevation. Unlike volume visualizations, which render each voxel (volume element) of a three-dimensional scene, mapping an image onto geometry efficiently creates the appearance of complexity by simply layering an image onto a surface. The resulting realism of the display also provides information that is not as readily apparent as with a simple display of either the image or the geometric surface.

Mapping an image onto a geometric surface is a two step process. First, the image is mapped onto the geometric surface in object space. Second, the surface undergoes view transformations (relating to the viewpoint of the observer) and is then displayed in 2D screen space. You can use IDL Direct Graphics or Object Graphics to display images mapped onto geometric surfaces.

The following table introduces the tasks and routines covered in this chapter.

Table 3-1: Tasks and Routines Associated with Mapping an Image onto Geometry 

Task
Routine(s)/Object(s)
Description

Mapping an Image onto Elevation Data.

SHADE_SURF

Display the elevation data.

IDLgrWindow::Init
IDLgrView::Init
IDLgrModel::Init

Initialize the objects necessary for an Object Graphics display.

IDLgrSurface::Init

Initialize a surface object containing the elevation data.

IDLgrImage::Init

Initialize an image object containing the satellite image.

XOBJVIEW

Display the object in an interactive IDL utility allowing rotation and resizing.

Mapping an Image onto a Sphere Using Direct Graphics.

MESH_OBJ
REPLICATE

Create a sphere.

SCALE3

Specify system variables required for 3D viewing.

SET_SHADING

Control the light source used by POLYSHADE.

TVSCL
POLYSHADE

Map the image onto the sphere using POLYSHADE and display the example with TVSCL.

Mapping an Image Object onto a Sphere (Object Programming).

MESH_OBJ
REPLICATE

Create a sphere.

IDLgrModel::Init
IDLgrPalette::Init
IDLgrImage::Init

Initialize model, palette and image objects.

FINDGEN
REPLICATE

Create normalized coordinates in order to map the image onto the sphere.

IDLgrPolygon::Init

Assign the sphere to a polygon object and apply the image object.

XOBJVIEW

Display the object in an interactive IDL utility allowing rotation and resizing.