Functions | |
int | Compute_Selection_By_Key (const char *action, const char *start_seg, HC_KEY key, const float *matrix) |
int | DCompute_Selection_By_Key (const char *action, const char *start_seg, HC_KEY key, const double *matrix) |
int Compute_Selection_By_Key | ( | const char * | action, |
const char * | start_seg, | ||
HC_KEY | key, | ||
const float * | matrix | ||
) |
Forces a selection event between a supplied shell, as referenced by a key, and a specified portion of a segment tree.
action | - One of "v", "^", "*", or "O". Action is compared against the selectability attribute settings as testing proceeds. See Set_Selectability() for a detailed explanation of actions. |
start_seg | - A segment somewhere in the tree belonging to a display driver, at which point it would be good to start selection testing. |
key | - Key to the Shell that should be used for testing. |
matrix | - A transformation matrix that should be applied to the shell before performing the selection. |
This routine forces a selection event that is of a special form where the selection object is provided in object space. The routine operates with a volume that is defined by the shell and is often used to implement collision detection operators. The process of first performing the selection event, and then querying the results is similar to the more standard selection process provided by Compute_Selection().
To allow for fast computation of Compute_Selection_By_Key(), shells from start_seg can be cross-referenced with spatial data structures (oct trees and/or bsp trees) that are retained between successive computations. To use this functionality, the selection event must be surrounded by calls to Begin_Shell_Selection() and End_Shell_Selection().
1. Use of Begin_Shell_Selection() constitutes a promise not to perform certain operations on anything contained in the segment tree until after the matching call to End_Shell_Selection(). See Begin_Shell_Selection() for details on the restrictions imposed.
2. Only facet-based geometries such as Shells, Meshes, NURBS Surfaces, Polygons, Polycylinders, etc. are selectable.
int DCompute_Selection_By_Key | ( | const char * | action, |
const char * | start_seg, | ||
HC_KEY | key, | ||
const double * | matrix | ||
) |
action | - One of "v", "^", "*", or "O". Action is compared against the selectability attribute settings as testing proceeds. See Set_Selectability() for a detailed explanation of actions. |
start_seg | - A segment somewhere in the tree belonging to a display driver, at which point it would be good to start selection testing. |
key | - Key to the Shell that should be used for testing. |
matrix | - A transformation matrix that should be applied to the shell before performing the selection. |