|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.rico.engine.geometry.collision.Ray
public class Ray
This class represents a ray. A ray can be used for triangle/line collision for example.
Constructor Summary | |
---|---|
Ray(Point3D origin,
Point3D dir)
Creates a new ray from the specified origin with the specified direction |
Method Summary | |
---|---|
Point3D |
getDirection()
Returns the direction vector of this ray |
Point3D |
getOrigin()
Returns the origin point of this ray. |
Point3D |
getPointAtDistance(float t)
Returns the point on the ray at the specified distance t. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Ray(Point3D origin, Point3D dir)
origin
- dir
- direction vector from the origin (point on the ray - origin)Method Detail |
---|
public Point3D getOrigin()
public Point3D getDirection()
public Point3D getPointAtDistance(float t)
t
- distance on the ray (usually between 0.0 and 1.0)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |