VIEWER Procedure

Lets users interactively define a 3D view, a slicing plane, and multiple cut-away volumes for volume rendering. (Creates a View Control and a View Orientation window in which to make these definitions.)

Usage

Input Parameters

Keywords

Cut_Plane(0, 0) The plane's angle of rotation about the x-axis.
Cut_Plane(1, 0) The plane's angle of rotation about the y-axis.
Cut_Plane(2, 0) Ignored.
Cut_Plane(0, 1) The x-coordinate of the center of the plane.
Cut_Plane(1, 1) The y-coordinate of the center of the plane.
Cut_Plane(2, 1) The z-coordinate of the center of the plane.


NOTE: The slicing plane is rotated about the y-axis first, then about the x-axis. If the variable passed to Cut_Plane is defined but is not a valid (3, 2) array, then controls to set the slicing plane are displayed, the initial (default) slicing plane is defined with no rotation about the x- or y-axes, and the center point of the plane is at (xdim/2, ydim/2, zdim/2).

ca(0, 0) x dimension of the first cut-away.
ca(1, 0) y dimension of the first cut-away.
ca(2, 0) z dimension of the first cut-away.
ca(3, 0) x position of the first cut-away.
ca(4, 0) y position of the first cut-away.
ca(5, 0) z position of the first cut-away.
ca(0:5, 1) Defines second cut-away (similar to ca(0:5, 0)).


NOTE: Setting Out_Mode to 1 ensures that VIEWER always sets up a view that is compatible with POLYSHADE. (POLYSHADE will not work properly if one or more polygon vertices lie outside the window.)

Discussion


NOTE: This procedure sets the system variables !P.T, !P.T3D, !X.S, !Y.S, and !Z.S, overriding any values you may have previously set. (These system variables are described in
Chapter 4, System Variables.)

Interactive Usage

Figure 2-141 The View Control window contains buttons used for setting the view, slicing plane, and cut-away volume parameters.

Figure 2-142 The View Control window contains buttons used for setting the view, slicing plane, and cut-away volume parameters.

TIP: It is advisable to use only the Ax, Az, and Zoom keywords when setting up a view for SURFACE or SHADE_SURF, since these procedures are limited in the type of viewing transformation they can utilize. (Other commands, such as PLOTS, POLYFILL, POLY_PLOT, and POLYSHADE, are compatible with most view transformations; therefore, you may freely use the Ay and Persp keywords when setting up the view for these routines.)
Figure 2-143 The View Orientation window displays a cube representing the current state of the parameters set in the View Control window.
Figure 2-144 The View Orientation window displays a cube representing the current state of the parameters set in the View Control window.

NOTE: If the zoom factor is large, or the perspective parameter is small, then the cube display in the View Orientation window may be erroneous. To cure the problem, reduce the zoom or increase the perspective (or set the perspective to NONE).

Windows Users: If you have a two-button mouse, use Alt in combination with the left mouse button.

Examples

See Also





doc@boulder.vni.com
Copyright © 1999, Visual Numerics, Inc. All rights reserved.