JNISpice
version 2.0.0

spice.basic
Class Ray

java.lang.Object
  extended by spice.basic.Ray

public class Ray
extends java.lang.Object

Class Ray represents rays in three-dimensional Euclidean space.

Rays always have unit-length direction vectors.

Version 1.0.0 03-DEC-2009 (NJB)


Constructor Summary
Ray()
          Zero-arguments constructor.
Ray(Ray r)
          Copy constructor.
Ray(Vector3 vertex, Vector3 direction)
          Create a Ray from a vertex and direction.
 
Method Summary
 Vector3 getDirection()
          Return a direction vector for this Ray..
 Vector3 getVertex()
          Return the vertex for this Ray..
 java.lang.String toString()
          Convert this Ray to a String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Ray

public Ray()
Zero-arguments constructor.


Ray

public Ray(Ray r)
Copy constructor. This constructor creates a deep copy.


Ray

public Ray(Vector3 vertex,
           Vector3 direction)
    throws SpiceException
Create a Ray from a vertex and direction.

The stored direction vector is a unit-length copy of the corresponding input vector.

Throws:
SpiceException
Method Detail

getVertex

public Vector3 getVertex()
Return the vertex for this Ray..


getDirection

public Vector3 getDirection()
Return a direction vector for this Ray..


toString

public java.lang.String toString()
Convert this Ray to a String.

Overrides:
toString in class java.lang.Object

JNISpice
version 2.0.0

JNISpice Alpha Test Version 2.0.0 28-JAN-2017 (NJB)