vtkPicker - select an actor by shooting a ray into a graphics window
Super Class: vtkObject
Description:
vtkPicker is used to select actors by shooting a ray into a graphics window and intersecting with the actor's bounding box. The ray is defined from a point defined in window (or pixel) coordinates, and a point located from the camera's position. vtkPicker may return more than one actor, since more than one bounding box may be intersected. vtkPicker returns the list of actors that were hit, the pick coordinates in world and untransformed mapper space, and the actor and mapper that are "closest" to the camera. The closest actor is the one whose center point (i.e., center of bounding box) projected on the ray is closest to the camera. vtkPicker has hooks for methods to call during the picking process. These methods are StartPickMethod(), PickMethod(), and EndPickMethod() which are invoked prior to picking, when something is picked, and after all picking candidates have been tested. Note that during the pick process the PickAction of vtkProp (and its subclasses such as vtkActor) is called prior to the pick action of vtkPicker.
Caveats:
vtkPicker and its subclasses will not pick actors that are "unpickable" (see vtkActor) or are fully transparent.
See Also:
vtkPicker is used for quick picking. If you desire to pick points or cells, use the subclass vtkPointPicker or vtkCellPicker, respectively.
Methods:
Detailed Method Descriptions:
vtkRenderer *GetRenderer () |
float *GetSelectionPoint () |
void SetTolerance (float ) | |
float GetTolerance () |
float *GetPickPosition () |
float *GetMapperPosition () |
vtkActor *GetAssembly () |
vtkActor *GetActor () |
vtkMapper *GetMapper () |
vtkDataSet *GetDataSet () |
vtkActorCollection *GetActors () |
vtkPoints *GetPickedPositions () |
int Pick (float ,float ,float ,vtkRenderer *) |
int Pick (float ,vtkRenderer *) |
void SetStartPickMethod (const ) |
void SetPickMethod (const ) |
void SetEndPickMethod (const ) |
void SetStartPickMethodArgDelete (const ) |
void SetPickMethodArgDelete (const ) |
void SetEndPickMethodArgDelete (const ) |
void SetPickFromList (int ) | |
int GetPickFromList () | |
void PickFromListOn () | |
void PickFromListOff () |
void InitializePickList () |
void AddPickList (vtkActor *) |
void DeletePickList (vtkActor *) |