Nori
|
Main scene data structure. More...
#include <scene.h>
Public Member Functions | |
Scene (const PropertyList &) | |
Construct a new scene object. | |
virtual | ~Scene () |
Release all memory. | |
const KDTree * | getKDTree () const |
Return a pointer to the scene's kd-tree. | |
const Integrator * | getIntegrator () const |
Return a pointer to the scene's integrator. | |
const Camera * | getCamera () const |
Return a pointer to the scene's camera. | |
const Sampler * | getSampler () const |
Return a pointer to the scene's sample generator (const version) | |
Sampler * | getSampler () |
Return a pointer to the scene's sample generator. | |
const std::vector< Mesh * > & | getMeshes () const |
Return a reference to an array containing all meshes. | |
bool | rayIntersect (const Ray3f &ray, Intersection &its) const |
Intersect a ray against all triangles stored in the scene and return detailed intersection information. | |
bool | rayIntersect (const Ray3f &ray) const |
Intersect a ray against all triangles stored in the scene and only determine whether or not there is an intersection. | |
const BoundingBox3f & | getBoundingBox () const |
Return an axis-aligned box that bounds the scene. | |
void | activate () |
Inherited from NoriObject::activate() | |
void | addChild (NoriObject *obj) |
Add a child object to the scene (meshes, integrators etc.) | |
QString | toString () const |
Return a brief string summary of the instance (for debugging purposes) | |
EClassType | getClassType () const |
Return the type of object (i.e. Mesh/BSDF/etc.) provided by this instance. |
Main scene data structure.
This class holds information on scene objects and is responsible for coordinating rendering jobs. It also provides useful query routines that are mostly used by the Integrator implementations.
Scene::Scene | ( | const PropertyList & | ) |
Construct a new scene object.
virtual Scene::~Scene | ( | ) | [virtual] |
Release all memory.
void Scene::activate | ( | ) | [virtual] |
Inherited from NoriObject::activate()
Initializes the internal data structures (kd-tree, luminaire sampling data structures, etc.)
Reimplemented from NoriObject.
void Scene::addChild | ( | NoriObject * | obj | ) | [virtual] |
Add a child object to the scene (meshes, integrators etc.)
Reimplemented from NoriObject.
const BoundingBox3f& Scene::getBoundingBox | ( | ) | const [inline] |
const Camera* Scene::getCamera | ( | ) | const [inline] |
EClassType Scene::getClassType | ( | ) | const [inline, virtual] |
Return the type of object (i.e. Mesh/BSDF/etc.) provided by this instance.
Implements NoriObject.
const Integrator* Scene::getIntegrator | ( | ) | const [inline] |
const KDTree* Scene::getKDTree | ( | ) | const [inline] |
const std::vector<Mesh *>& Scene::getMeshes | ( | ) | const [inline] |
const Sampler* Scene::getSampler | ( | ) | const [inline] |
Sampler* Scene::getSampler | ( | ) | [inline] |
bool Scene::rayIntersect | ( | const Ray3f & | ray, |
Intersection & | its | ||
) | const [inline] |
Intersect a ray against all triangles stored in the scene and return detailed intersection information.
ray | A 3-dimensional ray data structure with minimum/maximum extent information |
its | A detailed intersection record, which will be filled by the intersection query |
true
if an intersection was found bool Scene::rayIntersect | ( | const Ray3f & | ray | ) | const [inline] |
Intersect a ray against all triangles stored in the scene and only determine whether or not there is an intersection.
This method much faster than the other ray tracing function, but the performance comes at the cost of not providing any additional information about the detected intersection (not even its position).
ray | A 3-dimensional ray data structure with minimum/maximum extent information |
true
if an intersection was found QString Scene::toString | ( | ) | const [virtual] |
Return a brief string summary of the instance (for debugging purposes)
Implements NoriObject.