PEVMM3(3g) — Subroutines
Name
PEVMM3 − Returns a view mapping matrix.
Operating States: PHOP, ∗, ∗, ∗
PHIGS standard function
Syntax
PEVMM3 (VWWNLM, PJVPLM, PJTYPE, PJRX, PJRY, PJRZ, VPLD, BPLD, FPLD,
ERRIND, VWMPMT)
Argument Data Type Access Description
---------------------------------------------------------------------------
VWWNLM(4) Array of reals Read View window limits, in view
reference coordinates (UMIN, UMAX,
VMIN, VMAX)
PJVPLM(4) Array of reals Read Projection viewport limits, in
normalized projection coordinates
(XMIN, XMAX, YMIN, YMAX, ZMIN,
ZMAX)
PJTYPE Integer Read Projection type
PJRX, PJRY, Real Read Projection reference point, in view
PJRZ reference coordinates (x, y, z)
VPLD Real Read View plane distance, in view
reference coordinates
BPLD Real Read Back plane distance, in view
reference coordinates
FPLD Real Read Front plane distance, in view
reference coordinates
ERRIND Integer Write Error indicator
VWMPMT(4,4) Array of reals Write View mapping matrix
---------------------------------------------------------------------------
Constants
Defined Argument Constant Description
---------------------------------------------------------------------------
PJTYPE PPARL Parallel projection
PPERS Perspective projection
---------------------------------------------------------------------------
Description
PEVMM3 returns a view mapping matrix, which can be passed as input to the PSVWR3 function. The view mapping matrix in the view representation transforms the PHIGS coordinate system from view reference coordinate points to normalized projection coordinate points.
To create the view mapping matrix, use the following procedure:
•Specify window limits (view window) within view reference coordinate space in the order UMIN, UMAX, VMIN, VMAX.
The following restrictions apply:
UMIN < UMAX
VMIN < VMAX
The resulting view window is a rectangular region on the view plane with sides parallel to the u- and v-axes.
The formation of the u- and v-axes in the view reference coordinate system is described in Getting Started with DEC PHIGS.
•Specify projection viewport limits (view clipping limits) within normalized projection coordinate space in the order XMIN, XMAX, YMIN, YMAX, ZMIN, ZMAX.
The following restrictions apply:
XMIN < XMAX
YMIN < YMAX
ZMIN <= ZMAX
XMIN, XMAX, YMIN, and YMAX must be in the range [0,1], inclusive.
ZMIN and ZMAX must be in the range [0,1], inclusive.
The view clipping limits form a rectangular parallelepiped in normalized projection coordinate space with its edges parallel to the normalized projection coordinate axes. Although the normalized projection coordinate system conceptually extends beyond [0,1] x [0,1] x [0,1], the view clipping limits are located in the closed unit cube [0,1] x [0,1] x [0,1] in normalized projection coordinate space.
The view, back, and front planes are parallel to the uv-plane of the view reference coordinate system. They are specified as n coordinate values in the three plane arguments to this function.
The front- and back-plane values specify the front and back of the view volume. Conceptually, the view reference coordinate system is oriented to the view reference point, because the view reference coordinate points result from the view orientation transformation. (See the PEVOM3 function.) Therefore, the front plane should not be positioned behind the back plane.
The following restrictions apply to the view, front, and back planes:
•Back-plane distance < front-plane distance
•Back-plane distance = front-plane distance, if ZMIN = ZMAX
•The n coordinate of the projection reference point not equal to view plane distance
•For projection type = PERSPECTIVE,
the n coordinate of the projection reference point is either > front-plane distance or < back-plane distance
Projection and the coordinate systems are described in Getting Started with DEC PHIGS.
If the view mapping parameters are consistent and well defined (that is, if they conform to the specified rules and restrictions), a call to this function returns the 4 x 4 view mapping matrix. Otherwise, a nonzero error indicator is returned.
See Also
PEVOM3
PQVWF
PQVWR
PSVWI
PSVWR3