de.grogra.ray.light
Class DefaultLightProcessor

java.lang.Object
  extended by de.grogra.ray.light.DefaultLightProcessor
All Implemented Interfaces:
LightProcessor

public class DefaultLightProcessor
extends java.lang.Object
implements LightProcessor


Field Summary
protected  RTLight[] m_lights
           
protected  ShadowProcessor m_shadowProcessor
           
protected  Vector3d m_toLight
           
 
Constructor Summary
DefaultLightProcessor()
           
 
Method Summary
 int getLightRays(Ray view, IntersectionDescription desc, RayList rays)
          Adds lights/shadow rays that illuminalte the specified intersection point.
 void prepareLightProcessor(RTScene scene, IntersectionProcessor processor)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_lights

protected RTLight[] m_lights

m_shadowProcessor

protected ShadowProcessor m_shadowProcessor

m_toLight

protected final Vector3d m_toLight
Constructor Detail

DefaultLightProcessor

public DefaultLightProcessor()
Method Detail

getLightRays

public int getLightRays(Ray view,
                        IntersectionDescription desc,
                        RayList rays)
Description copied from interface: LightProcessor
Adds lights/shadow rays that illuminalte the specified intersection point.

Specified by:
getLightRays in interface LightProcessor
desc - description object that specifies the intersection point
rays - all determined rays are added to this object
Returns:
number of rays that are added to the rays object

prepareLightProcessor

public void prepareLightProcessor(RTScene scene,
                                  IntersectionProcessor processor)
Specified by:
prepareLightProcessor in interface LightProcessor