Class dnx.lr.PickTraversal
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class dnx.lr.PickTraversal

java.lang.Object
   |
   +----dnx.util.DNXObject
           |
           +----dnx.util.DNXInstancedObject
                   |
                   +----dnx.lr.Action
                           |
                           +----dnx.lr.Traversal
                                   |
                                   +----dnx.lr.InstanceTraversal
                                           |
                                           +----dnx.lr.TraversalPathTraversal
                                                   |
                                                   +----dnx.lr.InstancePathTraversal
                                                           |
                                                           +----dnx.lr.InstanceReturningTraversal
                                                                   |
                                                                   +----dnx.lr.SubtreePropertyTraversal
                                                                           |
                                                                           +----dnx.lr.Graphics3DTraversal
                                                                                   |
                                                                                   +----dnx.lr.PickTraversal

public class PickTraversal
extends Graphics3DTraversal
A PickTraversal is the parent class of traversals that implement "picking", i.e. returning the objects located under a particular section of screen space. The subclasses are RayPickTraversal (the object or objects hit by a ray, or equivalently, the object or objects under a particular position in screen space); and WindowPickTraversal (the object or objects enclosed in a rectangular window in screen space). This is a subclass of InstanceReturningTraversal, and so the methods on that class are standardly used to determine which node instances were hit as a result of the pick. In addition, each node instances has an associated PickDetail object, specifying more information about the pick -- e.g. where exactly the node instance was hit.

Constructor Index

 o PickTraversal()
Create a traversal with default contextInterest.
 o PickTraversal(int)
Create a traversal with specified contextInterest.

Method Index

 o addPick(PickDetail)
 o begin(NodeInstance)
Don't call this yourself.
 o enumeratePicks()
Enumerate all PickDetail objects.
 o getFirstPick()
Return the PickDetail object for the first instance picked.
 o getPick(int)
Return the PickDetail object for the Nth instance picked.
 o setPick(PickDetail)

Constructors

 o PickTraversal
  public PickTraversal()
Create a traversal with default contextInterest.
 o PickTraversal
  public PickTraversal(int contextInterest)
Create a traversal with specified contextInterest. Note that instance recording is set to true by default.

Methods

 o begin
  public void begin(NodeInstance inst)
Don't call this yourself. It's called automatically.
Overrides:
begin in class Graphics3DTraversal
 o enumeratePicks
  public final Enumeration enumeratePicks()
Enumerate all PickDetail objects.
 o getFirstPick
  public PickDetail getFirstPick()
Return the PickDetail object for the first instance picked.
 o getPick
  public PickDetail getPick(int n)
Return the PickDetail object for the Nth instance picked.
 o addPick
  protected void addPick(PickDetail p)
 o setPick
  protected void setPick(PickDetail p)

All Packages  Class Hierarchy  This Package  Previous  Next  Index