Superclass of all emitters. More...
#include <emitter.h>
Public Member Functions | |
virtual Color3f | sample (EmitterQueryRecord &lRec, const Point2f &sample) const =0 |
Sample the emitter and return the importance weight (i.e. the value of the Emitter divided by the probability density of the sample with respect to solid angles). More... | |
virtual Color3f | eval (const EmitterQueryRecord &lRec) const =0 |
Evaluate the emitter. More... | |
virtual float | pdf (const EmitterQueryRecord &lRec) const =0 |
Compute the probability of sampling lRec.p . More... | |
virtual Color3f | samplePhoton (Ray3f &ray, const Point2f &sample1, const Point2f &sample2) const |
Sample a photon. | |
virtual | ~Emitter () |
Virtual destructor. | |
virtual EClassType | getClassType () const override |
Return the type of object (i.e. Mesh/Emitter/etc.) provided by this instance. | |
void | setShape (Shape *shape) |
Set the shape if the emitter is attached to a shape. | |
Public Member Functions inherited from NoriObject | |
virtual | ~NoriObject () |
Virtual destructor. | |
virtual void | addChild (NoriObject *child) |
Add a child object to the current instance. More... | |
virtual void | setParent (NoriObject *parent) |
Set the parent object. More... | |
virtual void | activate () |
Perform some action associated with the object. More... | |
virtual std::string | toString () const =0 |
Return a brief string summary of the instance (for debugging purposes) | |
void | setIdName (const std::string &name) |
Allow to assign a name to the object. | |
const std::string & | getIdName () const |
Protected Attributes | |
Shape * | m_shape = nullptr |
Pointer to the shape if the emitter is attached to a shape. | |
Protected Attributes inherited from NoriObject | |
std::string | m_idname |
Additional Inherited Members | |
Public Types inherited from NoriObject | |
enum | EClassType { EScene = 0 , EMesh , ETexture , EBSDF , EPhaseFunction , EEmitter , EMedium , ECamera , EIntegrator , ESampler , ETest , EReconstructionFilter , EClassTypeCount } |
Static Public Member Functions inherited from NoriObject | |
static std::string | classTypeName (EClassType type) |
Turn a class type into a human-readable string. | |
|
pure virtual |
Evaluate the emitter.
lRec | A record with detailed information on the emitter query |
Implemented in AreaEmitter.
|
pure virtual |
Compute the probability of sampling lRec.p
.
This method provides access to the probability density that is realized by the sample() method.
lRec | A record with detailed information on the emitter query |
Implemented in AreaEmitter.
|
pure virtual |
Sample the emitter and return the importance weight (i.e. the value of the Emitter divided by the probability density of the sample with respect to solid angles).
lRec | An emitter query record (only ref is needed) |
sample | A uniformly distributed sample on |
Implemented in AreaEmitter.