Design: 04.02.01.02/P10

This is an abstract, language-independent design. Grim details may be found in the corresponding source code. You may return to the documentation for the module containing this program design, or to the entire hierarchical table of topics covered by the PVT.


PROGRAM 10: Polyline bundle index

CHARACTERISTICS: ynny

OPERATOR SCRIPT:

DEFINED POLYLINE INDICES: All lines but one are identical (drawn
with the same attributes).  Identify the line that is different.

UNDEFINED POLYLINE INDICES: A star is drawn with several
horizontal lines beneath it.  Normally, all of these will have
the same attributes as the star.  Count up and report the number
of lines which match the star in linetype, linewidth, and color.

DESIGN:

set all ASFs to BUNDLED

<inquire workstation state table lengths> to determine maximum
   number of entries in polyline table
szbt   = maximum size of bundle table

*** *** ***   polyline index

TEST: #SR 3 4 5 6
      "A defined polyline index should cause the addressed
       entry in the bundle table to be used when rendering a
       polyline."

bundis = number of bundles to be displayed = min(8, szbt)
initialize all of bundis to: linetype 1,
                             linewidth scale factor 1.0,
                             color index 1

bundif = randomly selected bundle from bundis
set bundif = linetype   = 2
             linewidth scale factor  = 2.0
             color      = 2

Display and label a polyline for each bundle in bundis

OPQA/DEFINED POLYLINE INDICES: which line is different?
pass/fail depending on (line with attributes from bundle #bundif
                        selected)

TEST: #SR 3 4 5 7
      "An undefined polyline index should cause bundle number 1
       in the polyline bundle table to be used when rendering a
       polyline."

set index #1 in bundle table to linetype   = 2
                                linewidth  = 2.0
                                line color = 2

u1,u2,u3 = 3 undefined, positive indices - all greater than
  maximum defined index in bundle table (szbt)
explct = number of explicit lines using bundle #1 = random integer
   from 0 to 4

draw star with bundle index 1

display interleaved:
  three lines using bundle index u1,u2,u3,
  explct lines using bundle index 1

OPQA/UNDEFINED POLYLINE INDICES: How many of the horizontal
  lines have the same attributes as the star?
pass/fail depending on response = 3+explct

END PROGRAM 10