math
Class IntersectionInfo

java.lang.Object
  extended by math.IntersectionInfo

public class IntersectionInfo
extends java.lang.Object

intersection info
contains all information needed for shading the surface, where the ray intersects the object


Field Summary
 boolean hit
           
 double nextDistance
           
 Vector3D nextNormal
           
 IObject nextObject
           
 OrthonormalBasis nextONB
           
 Point3D nextPosition
           
 Point2D nextTextureCoords
           
 Ray ray
           
 double t1
           
 IObject t1object
           
 double t2
           
 IObject t2object
           
 
Constructor Summary
IntersectionInfo()
          constructor
IntersectionInfo(double t1_, double t2_, Ray ray_, IObject object_at_t1, IObject object_at_t2)
          constructor
IntersectionInfo(IntersectionInfo intersection)
          copy constructor
 
Method Summary
 void setNextIntersectionNormal()
          sets the normal of the intersection 1
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

t1

public double t1

t1object

public IObject t1object

t2

public double t2

t2object

public IObject t2object

ray

public Ray ray

hit

public boolean hit

nextPosition

public Point3D nextPosition

nextDistance

public double nextDistance

nextObject

public IObject nextObject

nextNormal

public Vector3D nextNormal

nextONB

public OrthonormalBasis nextONB

nextTextureCoords

public Point2D nextTextureCoords
Constructor Detail

IntersectionInfo

public IntersectionInfo()
constructor


IntersectionInfo

public IntersectionInfo(IntersectionInfo intersection)
copy constructor

Parameters:
intersection - [in] intersection information

IntersectionInfo

public IntersectionInfo(double t1_,
                        double t2_,
                        Ray ray_,
                        IObject object_at_t1,
                        IObject object_at_t2)
constructor

Parameters:
t1_ - [in] distance to first intersection
t2_ - [in] distance to second intersection
ray_ - [in] the ray which intersects with an object
object_at_t1 - [in] first object to intersect
object_at_t2 - [in] second object to intersect
Method Detail

setNextIntersectionNormal

public void setNextIntersectionNormal()
sets the normal of the intersection 1