de.grogra.ray.tracing
Interface RayProcessor

All Known Implementing Classes:
BidirectionalPathTracer, DefaultRayTracer, PathTracerHS, PathTracerMT, PhotonMapping

public interface RayProcessor

An implementation of this interface encapsulates the raytracing algorithm. This class uses an IntersectionProcessor for determining intersection information about a single ray in the scene. Therefore it must not know the scene at all. It only interpretes the intersection information and sends out and traces new (reflected,fractured,..) rays.

Author:
Micha

Method Summary
 void getColorFromRay(Ray ray, Color4f color)
          The main methode of a ray processor.
 LightProcessor getLightProcessor()
           
 int getRecursionDepth()
           
 boolean hasFixedLightProcessor()
           
 void prepareRayProcessor(RTScene scene, IntersectionProcessor intersectionProcessor)
          With this method the processor is initialized with a 3d scene and an intersection processor it will use.
 void setLightProcessor(LightProcessor lightProcessor)
           
 void setRecursionDepth(int value)
           
 

Method Detail

getColorFromRay

void getColorFromRay(Ray ray,
                     Color4f color)
The main methode of a ray processor. This methode has to calculate a color (or luminance of the red, gren and blue ) for each ray.

Parameters:
ray - input - calculate for this ray
color - output - the calculated color

getLightProcessor

LightProcessor getLightProcessor()

getRecursionDepth

int getRecursionDepth()

hasFixedLightProcessor

boolean hasFixedLightProcessor()

prepareRayProcessor

void prepareRayProcessor(RTScene scene,
                         IntersectionProcessor intersectionProcessor)
With this method the processor is initialized with a 3d scene and an intersection processor it will use.

Parameters:
scene -
intersectionProcessor -

setLightProcessor

void setLightProcessor(LightProcessor lightProcessor)

setRecursionDepth

void setRecursionDepth(int value)