Scene Class Reference

#include <Scene.h>


Public Member Functions

 Scene ()
virtual ~Scene ()
ObjectgetObject () const
void setObject (Object *obj)
BackgroundgetBackground () const
void setBackground (Background *bg)
CameragetCamera () const
void setCamera (Camera *cam)
ImagegetImage () const
void setImage (Image *im)
void addLight (Light *light)
const std::vector< Light * > & getLights () const
Color getAmbient () const
void setAmbient (const Color &amb)
int getMaxRayDepth () const
void setMaxRayDepth (int rd)
double getMinAttenuation () const
void setMinAttenuation (double atten)
void preprocess ()
void render ()
double traceRay (Color &result, const RenderContext &context, const Ray &ray, const Color &attenuation, int depth) const
double traceRay (Color &result, const RenderContext &context, const Object *obj, const Ray &ray, const Color &attenuation, int depth) const


Detailed Description

Definition at line 21 of file Scene.h.


Constructor & Destructor Documentation

Scene  ) 
 

Definition at line 20 of file Scene.cc.

~Scene  )  [virtual]
 

Definition at line 30 of file Scene.cc.


Member Function Documentation

void addLight Light light  )  [inline]
 

Definition at line 54 of file Scene.h.

Referenced by Parser::parseScene().

Color getAmbient  )  const [inline]
 

Definition at line 61 of file Scene.h.

Referenced by LambertianMaterial::shade().

Background* getBackground  )  const [inline]
 

Definition at line 33 of file Scene.h.

Camera* getCamera  )  const [inline]
 

Definition at line 40 of file Scene.h.

Image* getImage  )  const [inline]
 

Definition at line 47 of file Scene.h.

const std::vector<Light*>& getLights  )  const [inline]
 

Definition at line 57 of file Scene.h.

Referenced by LambertianMaterial::shade().

int getMaxRayDepth  )  const [inline]
 

Definition at line 68 of file Scene.h.

double getMinAttenuation  )  const [inline]
 

Definition at line 74 of file Scene.h.

Object* getObject  )  const [inline]
 

Definition at line 26 of file Scene.h.

Referenced by LambertianMaterial::shade().

void preprocess  ) 
 

Definition at line 42 of file Scene.cc.

References Background::preprocess().

void render  ) 
 

Definition at line 54 of file Scene.cc.

References Background::getBackgroundColor(), HitRecord::getMaterial(), HitRecord::getPrimitive(), Image::getXresolution(), Image::getYresolution(), Object::intersect(), Camera::makeRay(), one_only, Image::set(), Material::shade(), xpixel, and ypixel.

void setAmbient const Color amb  )  [inline]
 

Definition at line 64 of file Scene.h.

Referenced by Parser::parseScene().

void setBackground Background bg  )  [inline]
 

Definition at line 36 of file Scene.h.

Referenced by Parser::parseScene().

void setCamera Camera cam  )  [inline]
 

Definition at line 43 of file Scene.h.

Referenced by Parser::parseScene().

void setImage Image im  )  [inline]
 

Definition at line 50 of file Scene.h.

void setMaxRayDepth int  rd  )  [inline]
 

Definition at line 71 of file Scene.h.

Referenced by Parser::parseScene().

void setMinAttenuation double  atten  )  [inline]
 

Definition at line 77 of file Scene.h.

Referenced by Parser::parseScene().

void setObject Object obj  )  [inline]
 

Definition at line 29 of file Scene.h.

Referenced by Parser::parseScene().

double traceRay Color result,
const RenderContext context,
const Object obj,
const Ray ray,
const Color attenuation,
int  depth
const
 

Definition at line 135 of file Scene.cc.

References Color::maxComponent().

double traceRay Color result,
const RenderContext context,
const Ray ray,
const Color attenuation,
int  depth
const
 

Definition at line 115 of file Scene.cc.

References Color::maxComponent().


The documentation for this class was generated from the following files:
Generated on Tue Jan 29 21:34:56 2008 for specter by  doxygen 1.4.6