[ Previous | Next | Contents | Glossary | Home | Search ]
The graPHIGS Programming Interface : Subroutine Reference

GPLG3 - Line Grid 3

GPLG3 (point, refv1, refv2, imin, imax, jmin, jmax)

Purpose

Use GPLG3 to insert a Line Grid 3 structure element into the open structure following the element pointer or to replace the element pointed at by the element pointer with a Line Grid 3 structure element depending on the current edit mode.

When encountered during structure traversal, this element generates a grid of lines in the plane defined by point, refv1, refv2 Each grid line is defined by the following parametric equations and is subject to all transformations and clipping.

The endpoints of the generated line segments are defined by the following equations. A line segment is generated for each pair of endpoints (P1 , P2 ) for each value of i and j.

Line segments parallel to V1 Line segments parallel to V2
P1 (j) = P0 + imin V1 + j V2 P1 (i) = P0 + i V1 + jmin V2
P2 (j) = P0 + imax V1 + j V2 P2 (i) = P0 + i V1 + jmax V2
where jmin <= j <= jmax where imin <= i <= imax

Polyline attributes are applied to this primitive.

GPLG3 is identified as GDP 1022.

Note:

Not all GDPs are supported on all workstations. Use the Inquire List of Generalized Drawing Primitives (GPQGD) subroutine (page GPQGD - Inquire List of Generalized Drawing Primitives) to determine the GDPs supported by an opened workstation. See also the workstation description in The graPHIGS Programming Interface: Technical Reference

Parameters

point -- specified by user, 3 short floating-point numbers (MC)

origin of grid (P0 )

refv1 -- specified by user, 3 short floating-point numbers (MC)

i reference vector (V1 ) This vector defines the direction of grid lines of constant j parameter and the spacing between grid lines of constant i parameter.

refv2 -- specified by user, 3 short floating-point numbers (MC)

j reference vector (V2 ) This vector defines the direction of grid lines of constant i parameter and the spacing between grid lines of constant j parameter.

imin -- specified by user, fullword integer

Minimum i parameter (imin ) This value defines the smallest value of i that is part of the grid (<=imax)

imax -- specified by user, fullword integer

Maximum i parameter (imax ) This parameter defines the largest value of i that is part of the grid (>=imin)

jmin -- specified by user, fullword integer

Minimum j parameter (jmin ) This parameter defines the smallest value of j that is part of the grid (<=jmax)

jmax -- specified by user, fullword integer

Maximum j parameter (jmax ) This parameter defines the largest value of j that is part of the grid (>=jmin)

Error Codes

5
FUNCTION REQUIRES STATE STOP OR NROP (NOT STCL)
107
REFERENCE VECTORS ARE COLINEAR
340
MINIMUM GRID LIMIT > MAXIMUM

Related Subroutines

GPLT
Set Linetype
GPLWSC
Set Linewidth Scale Factor
GPPLCD
Set Polyline Color Direct
GPPLCI
Set Polyline Color Index
GPPLET
Set Polyline End Type
GPPLI
Set Polyline Index

RCP code

201344259 (X'0C004503')


[ Previous | Next | Contents | Glossary | Home | Search ]