Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ pfillareaset3(3P) — PHIGS 1.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

FILL AREA SET 3(3P)  —  SUNPHIGS LIBRARY

NAME

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

SYNOPSIS

C Syntax

void
pfillareaset3 ( num_sets, sets )
Pintnum_sets;number of sets of points
Ppointlst3∗sets;array of sets

FORTRAN Syntax

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

Required PHIGS Operating States

(PHOP, ∗, STOP, ∗)

DESCRIPTION

Purpose

The FILL AREA SET 3 function puts a structure element containing the 3D specification of a FILL AREA SET 3 primitive into the currently open structure.  The FILL AREA SET 3 primitive is a group of implicitly closed polygonal areas. This allows for specifying areas with holes or disjoint coplanar regions.  The subroutine parameters specify the number of areas to be drawn, the number of points used to define each area, and the coordinates of each point.  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 3 attributes listed below. 

If the current edit mode is INSERT, the FILL AREA SET 3 element is inserted into the open structure after the element pointed to by the structure’s element pointer.  If the edit mode is REPLACE, the FILL AREA SET 3 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 3 element. 

Note: If the workstation is using a Graphics Processor:

1)A GP cannot process fill areas or fill area sets with more than 250 vertices; if a fill area or fill area set is encountered with more than 250 vertices, it will be rendered via software (i.e. not by the GP). 

2)There is also a limit on the size of the fill area or fill area set which the GP can process; this limit is a function of the number of bounds in the fill area sets and the total number of vertices. The function is: n_verts ∗ 3 ∗ sizeof(float) + n_bounds ∗ sizeof(short) < 2038 where: n_verts = total number of vertices in the primitive
n_bounds = number of boundaries in the primitive

3)If the application is performing HLHSR using the Z Buffer on the GP and a fill area or fill area set is encountered which cannot be rendered by the GP, it will rendered via software but will not be rendered into the Z Buffer. This will usually result in the image becoming incorrect. 

C Input Parameters

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

setsA pointer to a list num_sets long of Ppointlst3 structures.  Each Ppointlst3 structure defines a fill area. Ppointlst3 is defined in phigs.h as follows:

typedef struct {
Pintnumber;/∗ number of Ppoint3 structures in the list ∗/
Ppoint3∗points;/∗ list of points ∗/
} Ppointlst3;

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 Ppoint3 structures containing the coordinates of the fill area vertices in Modelling Coordinates. Ppoint3 is defined in phigs.h as follows:

typedef struct  {
Pfloatx;/∗ x coordinate ∗/
Pfloaty;/∗ y coordinate ∗/
Pfloatz;/∗ z coordinate ∗/
} Ppoint3;

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, PYA, and PZA 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. 

PZAAn array of N real values containing the z 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, PYA, and PZA 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 3 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 entire fill area set must be coplanar. 

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 edge of the areas is 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 the 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 3 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 3 (3P)
FILL AREA SET (3P)
FILL AREA SET 3 WITH DATA (3P+)

Sun Release 4.0  —  Last change: 1 August 1989

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