Class dnx.lr.RayPickTraversal
All Packages Class Hierarchy This Package Previous Next Index
Class dnx.lr.RayPickTraversal
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
|
+----dnx.lr.RayPickTraversal
- public class RayPickTraversal
- extends PickTraversal
A RayPickTraversal conceptually shoots a ray into a scene and
returns either the closest object hit by the ray, or all objects
hit by the ray. This is what you want if you want to find the
object or objects under the mouse.
-
PICK_ALL
-
-
PICK_CLOSEST
-
-
RayPickTraversal()
- Create a traversal with default contextInterest.
-
RayPickTraversal(int)
- Create a traversal with specified contextInterest.
-
begin(NodeInstance)
- Don't call this yourself.
-
enter(NodeInstance)
- Don't call this yourself.
-
getInterest()
- Return the pick interest.
-
getLimit()
-
-
getRay()
-
-
leave(NodeInstance)
- Don't call this yourself.
-
setInterest(int)
- Set the pick interest (i.e.
-
setLimit(float)
- Set the maximum distance that the pick will investigate.
-
setRay(Ray3)
- Set the ray for picking.
-
visit(NodeInstance)
- Don't call this yourself.
PICK_CLOSEST
public final static int PICK_CLOSEST
PICK_ALL
public final static int PICK_ALL
RayPickTraversal
public RayPickTraversal()
- Create a traversal with default contextInterest.
RayPickTraversal
public RayPickTraversal(int contextInterest)
- Create a traversal with specified contextInterest.
Note that instance recording is set to true by default.
setRay
public void setRay(Ray3 ray)
- Set the ray for picking.
setInterest
public void setInterest(int interest)
- Set the pick interest (i.e. whether you want the closest node
instance, or all node instances). Default is PICK_CLOSEST.
@param interest one of the constants PICK_CLOSEST or PICK_ALL
getInterest
public int getInterest()
- Return the pick interest.
setLimit
public void setLimit(float limit)
- Set the maximum distance that the pick will investigate.
Objects past this distance won't be returned.
getLimit
public float getLimit()
getRay
public Ray3 getRay()
begin
public void begin(NodeInstance inst)
- Don't call this yourself.
- Overrides:
- begin in class PickTraversal
enter
public void enter(NodeInstance inst)
- Don't call this yourself. It's called automatically.
- Overrides:
- enter in class Graphics3DTraversal
leave
public void leave(NodeInstance inst)
- Don't call this yourself. It's called automatically.
- Overrides:
- leave in class Graphics3DTraversal
visit
public int visit(NodeInstance inst)
- Don't call this yourself. It's called automatically.
- Overrides:
- visit in class InstanceTraversal
All Packages Class Hierarchy This Package Previous Next Index