Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

CELL ARRAY(3P)  —  Kubota Pacfic Computer Inc. (29 February 1991)

NAME

CELL ARRAY − create structure element specifying 2D cell array

SYNOPSIS

C Syntax

void
pcell_array ( rectangle, colr_array )
Prect∗rectangle;cell rectangle
Ppat_repcolr_array;colour array

Required PHIGS Operating States

(PHOP, ∗, STOP, ∗)

DESCRIPTION

Purpose

The CELL ARRAY function places a structure element containing the full specification of a 2D cell array into the currently open structure, according to the current edit mode.  A 2D cell array primitive is an array of cells with individual colours.  Its area is defined by two points in Modelling Coordinates giving the opposite corners of a rectangle, which is taken to be aligned with the modelling coordinate axes. 

If the current edit mode is INSERT, the CELL ARRAY element is inserted into the open structure after the element pointed to by the element pointer. If the edit mode is REPLACE, the CELL ARRAY element replaces the element pointed to by the element pointer. In either case, the element pointer is updated to point to the new CELL ARRAY element. 

C Input Parameters

rectangle
A pointer to a Prect structure giving the lower left and upper right corners of the rectangle that defines the area of the CELL ARRAY element.  The Prect structure is defined in phigs.h as:

typedef struct  {
Ppointp;/∗ lower left ∗/
Ppointq;/∗ upper right ∗/
} Prect;

The Ppoint structure is defined in phigs.h as:

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

colr_array
A pointer to the colour array. The Ppat_rep structure is defined in phigs.h as:

typedef struct  {
Pint_sizedims;/∗ patterns’s dimensions ∗/
Pint∗colr_array; /∗ colour index array ∗/
} Ppat_rep;

Pint_size is defined in phigs.h as follows:

typedef struct {
Pintsize_x;/∗ x size ∗/
Pintsize_y;/∗ y size ∗/
} Pint_size;

Execution

When the structure is traversed, the CELL ARRAY element draws the transformed boundaries of the cell rectangle, using the polyline attributes currently in effect.  This is the minimal simulation for cell arrays.  Applications should not depend on this behavior to remain the same in future releases. 

The aspect source flags (ASFs) for line type, line width scale factor, and polyline colour index control whether the values used for these attributes are taken from the polyline representation specified by POLYLINE INDEX (ASF - BUNDLED), or from the individual specifications set for these attributes (ASF - INDIVIDUAL). 

The coordinates used to specify the position of the CELL ARRAY primitive are Modelling Coordinates.  These can be any coordinate units that are convenient to the application.  At traversal, these coordinate values will be transformed by the current Local and Global Modelling Tranformations, the view representation selected by the current view index, and the workstation transformation current on the workstation to which the structure is posted. 

Attributes Applied

The current values of the following attributes will be used to display the CELL ARRAY primitive when the structure is traversed.  The value of an attribute is modified with the appropriate SET routine.  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. 

polyline colourpolyline colour index ASF
linewidth scale factorlinewidth scale factor ASF
linetypelinetype ASF
polyline shading methodpolyline shading method ASF
polyline index
depth cue index
name set

ERRORS

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

113Ignoring function, the colour index value is less than zero

117Ignoring function, one of the dimensions of the colour index array is less than zero

SEE ALSO

CELL ARRAY 3 (3P)

September 02, 1992

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