vtk
Class vtkPicker

java.lang.Object
  extended byvtk.vtkObjectBase
      extended byvtk.vtkObject
          extended byvtk.vtkAbstractPicker
              extended byvtk.vtkAbstractPropPicker
                  extended byvtk.vtkPicker
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
vtkCellPicker, vtkPointPicker

public class vtkPicker
extends vtkAbstractPropPicker
implements java.io.Serializable

vtkPicker - superclass for 3D geometric pickers (uses ray cast). vtkPicker is used to select instances of vtkProp3D 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 vtkProp3D, since more than one bounding box may be intersected. vtkPicker returns the list of props that were hit, the pick coordinates in world and untransformed mapper space, and the prop (vtkProp3D) and mapper that are "closest" to the camera. The closest prop is the one whose center point (i.e., center of bounding box) projected on the ray is closest to the camera. JavaBean wrapper for vtkPicker object.

Author:
vtk2jbean Automatic JavaBean wrapper for VTK.
See Also:
vtkPicker, is, used, for, quick, geometric, picking., If, you, desire, to, pick, points, or, cells,, use, the, subclass, vtkPointPicker, or, vtkCellPicker,, respectively., Or, you, may, use, hardware, picking, to, pick, any, type, of, vtkProp, -, see, vtkPropPicker, or, Serialized Form

Field Summary
protected  java.beans.PropertyChangeSupport changes
           
 
Fields inherited from class vtk.vtkObjectBase
vtkId
 
Constructor Summary
  vtkPicker()
           
protected vtkPicker(int dmy)
           
 
Method Summary
 vtkActorCollection getActors()
          Return a collection of all the actors that were intersected.
 java.lang.String getClassName()
          Return the class name as a string.
 vtkDataSet getDataSet()
          Get a pointer to the dataset that was picked (if any).
 vtkAbstractMapper3D getMapper()
          Return mapper that was picked (if any).
 double[] getMapperPosition()
          Return position in mapper (i.e., non-transformed) coordinates of pick point.
 vtkPoints getPickedPositions()
          Return a list of the points the the actors returned by GetActors were intersected at.
 vtkProp3DCollection getProp3Ds()
          Return a collection of all the prop 3D's that were intersected by the pick ray.
 vtkPicker getThisPicker()
           
 double getTolerance()
          Specify tolerance for performing pick operation.
 int isA(java.lang.String id0)
          Return 1 if this class is the same type of (or a subclass of) the named class.
 int pick(double[] id0, vtkRenderer id1)
          Perform pick operation with selection point provided.
 int pick(double id0, double id1, double id2, vtkRenderer id3)
          Perform pick operation with selection point provided.
 void setTolerance(double id0)
          Specify tolerance for performing pick operation.
protected  void VTKCastInit()
           
 void VTKInit()
           
 
Methods inherited from class vtk.vtkAbstractPropPicker
getActor, getActor2D, getAssembly, getPath, getProp, getProp3D, getPropAssembly, getThisAbstractPropPicker, getVolume, setPath
 
Methods inherited from class vtk.vtkAbstractPicker
addPickList, deletePickList, getPickFromList, getPickList, getPickPosition, getRenderer, getSelectionPoint, getThisAbstractPicker, initializePickList, pickFromListOff, pickFromListOn, setPickFromList
 
Methods inherited from class vtk.vtkObject
AddObserver, breakOnError, debugOff, debugOn, getDebug, getGlobalWarningDisplay, getMTime, getThisObject, globalWarningDisplayOff, globalWarningDisplayOn, hasObserver, hasObserver, invokeEvent, invokeEvent, modified, Print, PrintRevisions, register, removeObserver, removeObservers, removeObservers, setDebug, setGlobalWarningDisplay, unRegister
 
Methods inherited from class vtk.vtkObjectBase
addPropertyChangeListener, finalize, getReferenceCount, getThisObjectBase, isTypeOf, removePropertyChangeListener, setReferenceCount, VTKDelete
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

changes

protected java.beans.PropertyChangeSupport changes
Constructor Detail

vtkPicker

public vtkPicker()

vtkPicker

protected vtkPicker(int dmy)
Method Detail

getThisPicker

public vtkPicker getThisPicker()

getClassName

public java.lang.String getClassName()
Description copied from class: vtkObjectBase
Return the class name as a string. This method is defined in all subclasses of vtkObjectBase with the vtkTypeRevisionMacro found in vtkSetGet.h.

Overrides:
getClassName in class vtkAbstractPropPicker

isA

public int isA(java.lang.String id0)
Description copied from class: vtkObjectBase
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h.

Overrides:
isA in class vtkAbstractPropPicker

setTolerance

public void setTolerance(double id0)
Specify tolerance for performing pick operation. Tolerance is specified as fraction of rendering window size. (Rendering window size is measured across diagonal.)


getTolerance

public double getTolerance()
Specify tolerance for performing pick operation. Tolerance is specified as fraction of rendering window size. (Rendering window size is measured across diagonal.)


getMapperPosition

public double[] getMapperPosition()
Return position in mapper (i.e., non-transformed) coordinates of pick point.


getMapper

public vtkAbstractMapper3D getMapper()
Return mapper that was picked (if any).


getDataSet

public vtkDataSet getDataSet()
Get a pointer to the dataset that was picked (if any). If nothing was picked then NULL is returned.


getProp3Ds

public vtkProp3DCollection getProp3Ds()
Return a collection of all the prop 3D's that were intersected by the pick ray. This collection is not sorted.


getActors

public vtkActorCollection getActors()
Return a collection of all the actors that were intersected. This collection is not sorted. (This is a convenience method to maintain backward compatibility.)


getPickedPositions

public vtkPoints getPickedPositions()
Return a list of the points the the actors returned by GetActors were intersected at. The order of this list will match the order of GetActors.


pick

public int pick(double id0,
                double id1,
                double id2,
                vtkRenderer id3)
Perform pick operation with selection point provided. Normally the first two values for the selection point are x-y pixel coordinate, and the third value is =0. Return non-zero if something was successfully picked.

Overrides:
pick in class vtkAbstractPicker

pick

public int pick(double[] id0,
                vtkRenderer id1)
Perform pick operation with selection point provided. Normally the first two values for the selection point are x-y pixel coordinate, and the third value is =0. Return non-zero if something was successfully picked.

Overrides:
pick in class vtkAbstractPicker

VTKInit

public void VTKInit()
Overrides:
VTKInit in class vtkObject

VTKCastInit

protected void VTKCastInit()
Overrides:
VTKCastInit in class vtkAbstractPropPicker


Copyright © 2004 Sydney ViSLAB. All Rights Reserved.