lux::Scene Class Reference

#include <scene.h>

List of all members.

Public Member Functions

void Render ()
 Scene (Camera *c, SurfaceIntegrator *in, VolumeIntegrator *vi, Sampler *s, Primitive *accel, const vector< Light * > &lts, VolumeRegion *vr)
 ~Scene ()
bool Intersect (const Ray &ray, Intersection *isect) const
bool IntersectP (const Ray &ray) const
const BBoxWorldBound () const
SWCSpectrum Li (const RayDifferential &ray, const Sample *sample, float *alpha=NULL) const
SWCSpectrum Transmittance (const Ray &ray) const
void Start ()
void Pause ()
void Exit ()
int AddThread ()
void RemoveThread ()
double GetNumberOfSamples ()
double Statistics_SamplesPSec ()
double Statistics_SamplesPTotSec ()
double Statistics_Efficiency ()
double Statistics_SamplesPPx ()
void UpdateFramebuffer ()
unsigned char * GetFramebuffer ()
int DisplayInterval ()
int FilmXres ()
int FilmYres ()
double Statistics (const string &statName)
int CreateRenderThread ()
void RemoveRenderThread ()
void SignalThreads (int signal)

Public Attributes

Timer s_Timer
double lastSamples
double lastTime
Primitiveaggregate
vector< Light * > lights
Cameracamera
VolumeRegionvolumeRegion
SurfaceIntegratorsurfaceIntegrator
VolumeIntegratorvolumeIntegrator
Samplersampler
BBox bound
int seedBase
double numberOfSamplesFromNetwork
bool preprocessDone

Private Attributes

boost::mutex renderThreadsMutex
std::vector< RenderThread * > renderThreads
int CurThreadSignal


Detailed Description

Definition at line 69 of file scene.h.


Constructor & Destructor Documentation

Scene::Scene ( Camera c,
SurfaceIntegrator in,
VolumeIntegrator vi,
Sampler s,
Primitive accel,
const vector< Light * > &  lts,
VolumeRegion vr 
)

Scene::~Scene (  ) 

Definition at line 391 of file scene.cpp.

References aggregate, camera, lights, sampler, surfaceIntegrator, volumeIntegrator, and volumeRegion.


Member Function Documentation

int Scene::AddThread (  ) 

Definition at line 69 of file scene.cpp.

References CreateRenderThread().

Referenced by lux::Context::addThread().

int Scene::CreateRenderThread (  ) 

int Scene::DisplayInterval (  ) 

Definition at line 86 of file scene.cpp.

References camera, lux::Camera::film, and lux::Film::getldrDisplayInterval().

Referenced by Statistics().

void Scene::Exit (  ) 

Definition at line 64 of file scene.cpp.

References lux::RenderThread::SIG_EXIT, and SignalThreads().

Referenced by lux::Context::exit().

int Scene::FilmXres (  ) 

Definition at line 90 of file scene.cpp.

References camera, lux::Camera::film, and lux::Film::xResolution.

Referenced by Statistics().

int Scene::FilmYres (  ) 

Definition at line 94 of file scene.cpp.

References camera, lux::Camera::film, and lux::Film::yResolution.

Referenced by Statistics().

unsigned char * Scene::GetFramebuffer (  ) 

Definition at line 82 of file scene.cpp.

References camera, lux::Camera::film, and lux::Film::getFrameBuffer().

Referenced by lux::Context::framebuffer().

double Scene::GetNumberOfSamples (  ) 

bool lux::Scene::Intersect ( const Ray ray,
Intersection isect 
) const [inline]

bool lux::Scene::IntersectP ( const Ray ray  )  const [inline]

SWCSpectrum Scene::Li ( const RayDifferential ray,
const Sample sample,
float *  alpha = NULL 
) const

void Scene::Pause (  ) 

Definition at line 59 of file scene.cpp.

References s_Timer, lux::RenderThread::SIG_PAUSE, SignalThreads(), and Timer::Stop().

Referenced by lux::Context::pause().

void Scene::RemoveRenderThread (  ) 

Definition at line 331 of file scene.cpp.

References renderThreads, renderThreadsMutex, and lux::RenderThread::SIG_EXIT.

Referenced by RemoveThread().

void Scene::RemoveThread (  ) 

Definition at line 73 of file scene.cpp.

References RemoveRenderThread().

Referenced by lux::Context::removeThread().

void Scene::Render (  ) 

void Scene::SignalThreads ( int  signal  ) 

Definition at line 202 of file scene.cpp.

References CurThreadSignal, renderThreads, and renderThreadsMutex.

Referenced by Exit(), Pause(), and Start().

void Scene::Start (  ) 

Definition at line 54 of file scene.cpp.

References s_Timer, lux::RenderThread::SIG_RUN, SignalThreads(), and Timer::Start().

Referenced by lux::Context::start().

double Scene::Statistics ( const string &  statName  ) 

double Scene::Statistics_Efficiency (  ) 

Definition at line 181 of file scene.cpp.

References renderThreads, and renderThreadsMutex.

Referenced by Statistics().

double Scene::Statistics_SamplesPPx (  ) 

Definition at line 143 of file scene.cpp.

References camera, lux::Camera::film, GetNumberOfSamples(), and lux::Film::GetSampleExtent().

Referenced by Statistics().

double Scene::Statistics_SamplesPSec (  ) 

double Scene::Statistics_SamplesPTotSec (  ) 

Definition at line 169 of file scene.cpp.

References GetNumberOfSamples(), preprocessDone, s_Timer, Timer::Time(), and cimg_library::cimg::time().

Referenced by Statistics().

SWCSpectrum Scene::Transmittance ( const Ray ray  )  const

void Scene::UpdateFramebuffer (  ) 

Definition at line 78 of file scene.cpp.

References camera, lux::Camera::film, and lux::Film::updateFrameBuffer().

Referenced by lux::Context::updateFramebuffer().

const BBox & Scene::WorldBound (  )  const


Member Data Documentation

Definition at line 117 of file scene.h.

Referenced by Intersect(), IntersectP(), Scene(), and ~Scene().

Definition at line 124 of file scene.h.

Referenced by Scene(), and WorldBound().

Definition at line 139 of file scene.h.

Referenced by CreateRenderThread(), Render(), and SignalThreads().

Definition at line 108 of file scene.h.

Referenced by Scene(), and Statistics_SamplesPSec().

Definition at line 108 of file scene.h.

Referenced by Scene(), and Statistics_SamplesPSec().

Definition at line 128 of file scene.h.

Referenced by GetNumberOfSamples(), Scene(), and lux::FlexImageFilm::UpdateFilm().

std::vector<RenderThread*> lux::Scene::renderThreads [private]

boost::mutex lux::Scene::renderThreadsMutex [private]

Definition at line 121 of file scene.h.

Referenced by CreateRenderThread(), Render(), Scene(), lux::FlexImageFilm::WriteImage(), and ~Scene().


The documentation for this class was generated from the following files:

Generated on Mon May 18 07:13:51 2009 for lux by  doxygen 1.5.8