Masks are provided for points, lines, polygons, and triangle strips. By default, the input data and output data are identical. If a mask is specified, only those points used by the selected data are copied into the output data, and the points are renumbered as appropriate. For example, if a single line is selected and uses the five points (11,24,7,9,22), only these five points would be copied into the output data, and they would be renumbered (3,5,1,2,4).
If a point mask is specified, only the "on" points and each "on" geometric primitive (line, polygon, triangle strip) that has every point on are passed as output. If no point mask is specified, all "on" geometric primitives and their associated points are passed.
point_mask_size The number of entries in the point mask.
line_mask An integer array of (0,1) representing on/off selection of lines.
line_mask_size The number of entries in the line mask.
polygon_mask An integer array of (0,1) representing on/off selection of polygons.
polygon_mask_size The number of entries in the polygon mask.
triangle_strip_mask An integer array of (0,1) representing on/off selection of triangle_strips.
triangle_strip_mask_size The number of entries in the triangle_strip mask.
point_mask_size? Get the number of entries in the point mask.
point_mask= (v1, v2, ...) Set the point mask.
point_mask+ (v1, v2, ...) Add to the point mask.
line_mask? Get the line mask entries.
line_mask_size? Get the number of entries in the line mask.
line_mask= (v1, v2, ...) Set the line mask.
line_mask+ (v1, v2, ...) Add to the line mask.
polygon_mask? Get the polygon mask entries.
polygon_mask_size? Get the number of entries in the polygon mask.
polygon_mask= (v1, v2, ...) Set the polygon mask.
polygon_mask+ (v1, v2, ...) Add to the polygon mask.
triangle_strip_mask? Get the triangle_strip mask entries.
triangle_strip_mask_size? Get the number of entries in the triangle_strip mask.
triangle_strip_mask= (v1, v2, ...) Set the triangle_strip mask.
triangle_strip_mask+ (v1, v2, ...) Add to the triangle_strip mask.
/* * Script creates display data, selects one line, and places spheres at each point */ /* * Create display data and filter network */ display_data new: dd points=(0,0,0, 1,0,0, 0,1,0) lines=(2,1,2,2,2,3,2,1,3) scalars=(0,1,2) vectors=(1,0,0,0,1,0,0,0,1) ; mask_data new: mask data_in=dd line_mask=(0,0,1) ; sphere_modeller new:sm radius=.1 resolution=2 ; data_primitive new:spheres data_in=mask modeller=sm range=(0,2) ; /* * The thread to hold the pearls together */ display_lines new: thread scalar_data_off! data_in=mask ; actor new: thread_actor color=(1,1,1) modeller=thread ; /* * set up cameras and lights */ camera new: acamera view_up=(0,0,1) position=(1,1,1) x_range=(-1,1) y_range=(-1,1) z_range=(-1,1)
default! on!;
light new: l1 position=([acamera position?]) on!;
actor new:sphere_actor modeller=spheres;
/* * define the renderers */ environment new: _env variable="LYMB_RENDERER"; string new: current_renderer = [_env value?]; object# current_renderer new: main_renderer actors=([actor instances?]) cameras=acamera lights=l1;
/* * Draw the picture */ main_renderer render!;