<<<<<<<<<<<<<<<<<

data_geometry(display) Display data_geometry(display)

NAME

data_geometry - create geometric structure associated with data.

DESCRIPTION

Data_geometry takes a data set (e.g., visage_data_set, plot3d_data_set, etc.) as input and creates a display_data as output. The output display_data represents the geometry of the data set, and depends upon the type of data set provided as input.

If the input data set is a structured point set or structured grid set, the geometry representation depends upon the instance variable Extent, which is a 6-vector, describes a geometry based on the (imin,imax,jmin,jmax,kmin,kmax) values. Depending on the values provided, the geometry may either be a point, line, surface, or volume.

If the input data set is an unstructered grid set, extent is currently ignored and the geometry created consists of all 0D, 1D, 2D elements in the mesh, plus the faces of any 3D elements that are not used by two 3D elements.

SUPERCLASS

computed_feature

INSTANCE VARIABLES

extent a 6-vector containing the min/max pairs of data_set coordinate system.

MESSAGES

extent= (x1_min,x1_max, x2_min,x2_max, x3_min,x3_max) Set the extent of the geometry.

extent? Get the extent of the geometry.

EXAMPLE

In this example a plot3d data file is read and an outline and a grid plane are created.

/* * read in the data */ string new: data_name=case1;

plot3d_reader new: areader file_prefix=data_name read! ; /* * Set up the data set */

string new: data_set = data_name + "_gridset01";

object# data_set compute_properties! ; /* * set up some displays: outline and plane */ data_outline new: outline data_in= data_set ; display_lines new: draw_outline data_in=outline ; actor new: outline_actor modeller= draw_outline ;

data_geometry new: plane data_in= data_set extent= (1,100,1,100,1,1) ; display_all new: draw_plane data_in= plane ; actor new: plane_actor modeller= draw_plane ;

/* * Rendering stuff */ vector new: bbox dimension=6; bbox = ([object# data_set bounds?]); camera new: acamera position=(1,1,1) x_range=([bbox @1 ?],[bbox @2 ?]) y_range=([bbox @3 ?],[bbox @4 ?]) z_range=([bbox @5 ?],[bbox @6 ?]) default! on! ;

light new: alight position=(30,30,50) on! ;

logic new: test; environment new: _env variable="LYMB_RENDERER"; test = [_env defined?] false: "#Environment variable LYMB_RENDERER must be set." false: "parser exit!;"

; string new: current_renderer = [_env value?];

object# current_renderer new: main_renderer actors=([actor instances?]) lights=alight cameras=acamera render! ;

SEE ALSO

computed_feature, data_outline, plot3d_reader, display_data


Please send comments and suggestions to
consult@rpi.edu