Render queue - used to keep track of a number of scenes that are simultaneously being rendered. More...
#include <mitsuba/render/renderqueue.h>
Public Member Functions | |
RenderQueue () | |
Create a new render queue. More... | |
size_t | getJobCount () const |
Return the current number of jobs in the queue. More... | |
void | addJob (RenderJob *thr) |
Add a render job to the queue. More... | |
void | removeJob (RenderJob *thr, bool wasCancelled) |
Remove a (finished) render job from the queue. More... | |
Float | getRenderTime (const RenderJob *job) const |
Return the amount of time spent rendering the given job (in seconds) More... | |
void | registerListener (RenderListener *listener) |
Register a render listener. More... | |
void | unregisterListener (RenderListener *listener) |
Unregister a render listener. More... | |
void | waitLeft (size_t njobs) const |
void | join () const |
Releases resources held by recently finished jobs. More... | |
void | flush () |
Cause all render jobs to write out the current image. More... | |
void | signalWorkBegin (const RenderJob *job, const RectangularWorkUnit *wu, int worker) |
void | signalWorkEnd (const RenderJob *job, const ImageBlock *block, bool cancelled) |
void | signalWorkCanceled (const RenderJob *job, const Point2i &offset, const Vector2i &size) |
void | signalFinishJob (const RenderJob *job, bool cancelled) |
void | signalRefresh (const RenderJob *job) |
virtual const Class * | getClass () const |
Retrieve this object's class. More... | |
Public Member Functions inherited from Object | |
Object () | |
Construct a new object. More... | |
int | getRefCount () const |
Return the current reference count. More... | |
void | incRef () const |
Increase the reference count of the object by one. More... | |
void | decRef (bool autoDeallocate=true) const |
Decrease the reference count of the object and possibly deallocate it. More... | |
virtual std::string | toString () const |
Return a human-readable string representation of the object's contents. More... | |
Static Public Attributes | |
static Class * | m_theClass |
Static Public Attributes inherited from Object | |
static Class * | m_theClass |
Pointer to the object's class descriptor. More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from Object | |
static void | staticInitialization () |
Initializes the built-in reference count debugger (if enabled) More... | |
static void | staticShutdown () |
Free the memory taken by staticInitialization() More... | |
Protected Member Functions inherited from Object | |
virtual | ~Object () |
Virtual private deconstructor. (Will only be called by ref) More... | |
Render queue - used to keep track of a number of scenes that are simultaneously being rendered.
This class is also responsible for distributing events about in-progress renderings to registered listeners.
mitsuba::RenderQueue::RenderQueue | ( | ) |
Create a new render queue.
void mitsuba::RenderQueue::addJob | ( | RenderJob * | thr | ) |
Add a render job to the queue.
void mitsuba::RenderQueue::flush | ( | ) |
Cause all render jobs to write out the current image.
|
virtual |
Retrieve this object's class.
Reimplemented from Object.
|
inline |
Return the current number of jobs in the queue.
Return the amount of time spent rendering the given job (in seconds)
void mitsuba::RenderQueue::join | ( | ) | const |
Releases resources held by recently finished jobs.
void mitsuba::RenderQueue::registerListener | ( | RenderListener * | listener | ) |
Register a render listener.
Remove a (finished) render job from the queue.
void mitsuba::RenderQueue::signalRefresh | ( | const RenderJob * | job | ) |
void mitsuba::RenderQueue::signalWorkBegin | ( | const RenderJob * | job, |
const RectangularWorkUnit * | wu, | ||
int | worker | ||
) |
void mitsuba::RenderQueue::signalWorkCanceled | ( | const RenderJob * | job, |
const Point2i & | offset, | ||
const Vector2i & | size | ||
) |
void mitsuba::RenderQueue::signalWorkEnd | ( | const RenderJob * | job, |
const ImageBlock * | block, | ||
bool | cancelled | ||
) |
void mitsuba::RenderQueue::unregisterListener | ( | RenderListener * | listener | ) |
Unregister a render listener.
void mitsuba::RenderQueue::waitLeft | ( | size_t | njobs | ) | const |
Wait until the queue contains a certain number of scenes (or less).
|
static |