rcrt::RayCaster Class Reference

#include <RayCaster.h>

Inheritance diagram for rcrt::RayCaster:

Inheritance graph
[legend]
Collaboration diagram for rcrt::RayCaster:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 RayCaster (Scene *s)
virtual ~RayCaster ()
virtual RGBColor trace (Ray &r) const
virtual Image trace (Camera *cam, std::vector< Primitive * > *prList) const


Detailed Description

Very simple Tracer, just checks for direct light, does not trace any reflection/refraction

Definition at line 11 of file RayCaster.h.


Constructor & Destructor Documentation

rcrt::RayCaster::RayCaster ( Scene s  ) 

Definition at line 15 of file RayCaster.cpp.

rcrt::RayCaster::~RayCaster (  )  [virtual]

Definition at line 19 of file RayCaster.cpp.


Member Function Documentation

RGBColor rcrt::RayCaster::trace ( Ray r  )  const [virtual]

Trace the given ray and return the (approximated) radiance that is coming in at the ray origin, from -ray_direction.

Parameters:
r the ray
Returns:
the radiance

Implements rcrt::TracingStrategy.

Definition at line 23 of file RayCaster.cpp.

References rcrt::RGBColor::BLACK, rcrt::Scene::castShadows(), rcrt::Ray::dir(), rcrt::LightSample::dirToLight(), rcrt::LightSample::dist(), rcrt::Scene::getLights(), rcrt::Object::getMaterial(), rcrt::Light::getMinSamples(), rcrt::Primitive::getParent(), rcrt::Intersection::getPosition(), rcrt::Intersection::getPrimitive(), rcrt::Light::getSampler(), rcrt::Intersection::getSNormalW(), rcrt::Light::hasSampler(), rcrt::Light::illuminate(), rcrt::Scene::intersect(), rcrt::Scene::isOccluded(), rcrt::Intersection::isValid(), rcrt::LightSample::power(), rcrt::Material::sample(), rcrt::LightSampler::sample(), rcrt::TracingStrategy::scene, and rcrt::LightSample::weight().

Referenced by testLoaders().

Image rcrt::RayCaster::trace ( Camera cam,
std::vector< Primitive * > *  prList 
) const [virtual]

Definition at line 61 of file RayCaster.cpp.

References rcrt::RGBColor::b(), rcrt::Scene::castShadows(), rcrt::Ray::dir(), rcrt::LightSample::dirToLight(), rcrt::LightSample::dist(), rcrt::RGBColor::g(), rcrt::Intersection::getDistance(), rcrt::Scene::getLights(), rcrt::Object::getMaterial(), rcrt::Light::getMinSamples(), rcrt::Primitive::getParent(), rcrt::Intersection::getPosition(), rcrt::Intersection::getPrimitive(), rcrt::Camera::getRay(), rcrt::Camera::getResolutionX(), rcrt::Camera::getResolutionY(), rcrt::Intersection::getSNormalW(), rcrt::Light::illuminate(), rcrt::Scene::isOccluded(), rcrt::Intersection::isValid(), rcrt::LightSample::power(), rcrt::RGBColor::r(), rcrt::Material::sample(), rcrt::TracingStrategy::scene, rcrt::Image::setPixel(), rcrt::Ray::tris, and rcrt::LightSample::weight().


The documentation for this class was generated from the following files:
Generated on Thu Jan 31 19:33:26 2008 for RenderingCompetitionRayTracer by  doxygen 1.5.3