Indirect addressing eliminates the need for data transfer
each time new data are required. This is accomplished by
dimensioning the array which holds the band information in
two dimensions - CONTOUR (n,2), where n is the maximum num
ber of grid cells in one row. Each column represents one
band of data and is addressed via the variables FIRST and
SECOND. These variables contain either the value one or two
depending upon which is the current working band and which
is the neighbor band. Thus when new data are required the
addresses in FIRST and SECOND are swapped and the new
information is read into the array CONTOUR (n,SECOND).
Utilization of these techniques provides for the rapid
display of digital information in DEMGS. The approaches and
techniques used in the different software 'package' used in
DEMGS follows.
Contour Band Ilap (DC3M)
The contour band map (or choropleth map of elevation), con
sists of two processes. The first is a classification of
the data elements into the appropriate class interval, and
the second is the display of the resultant information. In
this type of display all elevations which are in a given
class are drawn with the same color.
In order to classify the data, the method of equal intervals
was selected for maximum efficiency, since the algorithm for
this process eliminates the need for any comparisions. The
only information required was the elevation range, minimum
elevation, and the number of class intervals. The first two
elements can be derived from the header information in the
H-file and the last is set to a maximum of sixteen (which is
the number of colors available) but can be reset by the user
to a lower value. The elevation range is calculated from
the maximum and minimum elevations in the H-file. In order
to classify the data an increment value is necessary as
well, which is calculated as follows:
INCREMENT = (MAXE - MINE) / NCLASS (1)
Where,
MAXE is the maximum elevation of the DEM,
MINE is the minimum elevation, and
NCLASS is the number of class intervals.
Given this, the elevation class of a pixel is:
CLASS = (ELEV - MINE) / INCREMENT (2)
Where, ELEV is the current working elevation, and CLASS is
the integer (truncated) value of the operation.
After the classification process, which is accomplished
during data transfer the information must be plotted. This
is done in two stages. The first is to defer the actual
drawing command until the classification changes by using a
run-time run-length computation; this approach was taken to
speed up the display since each DRAW command in the DEMGS
hardware environment generates a CPU interrupt, thus by only
drawing lines instead of points, the drawing time is min
imized. The second stage is to use the class value as the