Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ fill_area_set(3P) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

FILL AREA SET(3P)  —  SUNPHIGS LIBRARY

NAME

FILL AREA SET − create a structure element specifying a 2D fill area set primitive

SYNOPSIS

C Syntax

void
pfillareaset ( num_sets, sets )
Pintnum_sets;number of sets of points
Ppointlst∗sets;array of sets

FORTRAN Syntax

SUBROUTINE pfas ( NPL, IXA, PXA, PYA )
INTEGERNPLnumber of point lists
INTEGERIXA(NPL)array of end indices for the point lists
REALPXA(∗), PYA(∗)coordinates of points (MC)

Required PHIGS Operating States

(PHOP, ∗, STOP, ∗)

DESCRIPTION

Purpose

The FILL AREA SET function puts a structure element containing the 2D specification of a FILL AREA SET primitive into the currently open structure.  The FILL AREA SET primitive is a group of implicitly closed polygonal areas.  This allows for specifying areas with holes or disjoint regions.  The subroutine parameters specify the number of fill areas to be drawn, the number of points used to define each, and the Modelling coordinates of each point.  The z coordinates are assumed to be zeroes.  Each set of points defines a separate closed area.  All of the areas specified in a single function call are drawn using the current values of the FILL AREA SET attributes listed below. 

If the current edit mode is INSERT, the structure element created by the FILL AREA SET subroutine is inserted into the open structure after the element pointed to by the structure’s element pointer.  If the edit mode is REPLACE, the new FILL AREA SET element replaces the element pointed to by the element pointer. In either case, the element pointer is updated to point to the new FILL AREA SET element. 

Note: see the FILL AREA SET 3 reference manual page for a description of the limitations of using FILL AREA SET on a Graphics Processor. 

C Input Parameters

num_sets
The number of sets of points to be specified. Each set of points defines a separate closed area.

setsA pointer to a list num_sets long of Ppointlst structures.  Each Ppointlst structure defines one of the fill areas in the set.  Ppointlst is defined in phigs.h as follows:

typedef struct {
Pintnumber;/∗ number of points in the list ∗/
Ppoint∗points;/∗ pointer to list of points ∗/
} Ppointlst;

The number component specifies the number of points used to define the fill area. The points component is a pointer to a list, number long, of Ppoint structures which contain the Modelling Coordinates of each vertex of the fill area. Ppoint is defined in phigs.h as follows:

typedef struct {
Pfloatx;/∗ x coordinate ∗/
Pfloaty;/∗ y coordinate ∗/
} Ppoint;

FORTRAN Input Parameters

NPLThe number of point lists, or sets of points, to be specified.  Each set of points defines a separate closed area. 

IXAAn array of NPL integers containing the end indices in the PXA and PYA arrays for each set of points. 

PXAAn array of N real values containing the x coordinates of the FILL AREA SET. 

PYAAn array of N real values containing the y coordinates of the FILL AREA SET. 

The first fill area in the set is defined by the points from 1 to IXA(1) in the PXA and PYA arrays, the second fill area is defined by the points from IXA(1) + 1 to IXA(2), etc. 

Execution

When the structure is traversed, the FILL AREA SET element draws the specified number of closed polygonal areas using the given points.  Each fill area forms a boundary by connecting the specified points in order.  SunPHIGS will implicitly close each area by extending the boundary of the fill area from the last point to the first. 

The points are specified in Modelling Coordinates. These may be any coordinate units that are convenient to the application.  At traversal, these coordinates are transformed by the current Local and global modelling transformations, the view representation selected by the current view index, and the workstation transformation current on the workstation to which the structure is posted. 

All the specified areas are drawn using the current values of the primitive attributes listed below. The edge attributes, EDGE FLAG, EDGETYPE, EDGEWIDTH SCALE FACTOR and EDGE COLOUR INDEX allow you to control whether, and how, the edges of the areas are displayed independently of the interior representation. 

Using Edge Attributes With Interior Style HOLLOW

If edges are not displayed, and the INTERIOR STYLE is HOLLOW, only the boundaries of the fill areas are drawn using the interior colour.  If edges are displayed when the INTERIOR STYLE is HOLLOW, the edges will overlay the boundaries using the edge colour.  If the EDGETYPE is a broken line, the boundaries will show through the breaks in the edge representation. 

Attributes Applied

The attributes listed below are used to display the FILL AREA SET primitive when the structure is traversed.  The Aspect Source Flags (ASFs) tell where to access the output display attributes.  These attributes can come directly from the traversal state list, or they can be accessed indirectly, using the appropriate index in the traversal state list and the corresponding bundled representation in the workstation state list. 

interior colourinterior colour index ASF
back interior colourback interior colour ASF
interior styleinterior style ASF
back interior styleback interior style ASF
interior style indexinterior style index ASF
back interior style indexback interior style index ASF
interior shading methodinterior shading method ASF
back interior shading methodback interior shading method ASF
interior reflectance equation interior reflectance equation ASF
back interior reflectance equationback interior reflectance equation ASF
area propertiesarea properties ASF
back area propertiesback area properties ASF
interior index
edge colouredge colour index ASF
edge flagedge flag ASF
edgetypeedgetype ASF
edgewidth scale factoredgewidth scale factor ASF
edge index
face distinguishing mode
face culling mode
depth cue index
light source state
name set

ERRORS

005Ignoring function, function requires state (PHOP, ∗, STOP, ∗)

SEE ALSO

FILL AREA (3P)
FILL AREA SET 3 (3P)
FILL AREA SET 3 WITH DATA (3P+)

Sun Release 4.0  —  Last change: 29 July 1989

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026