The functions and elements of an Emitter. More...
#include <Emitter.h>
Public Member Functions | |
Emitter (const ngl::Vec3 _location=ngl::Vec3(0, 0, 0), const float _size=1.0, const float _emitDensityRate=4.0, const float _emitTemperatureRate=4.0) | |
Constructor for Emitter. | |
~Emitter () | |
Destructor for Emitter. | |
float | getEmitDensityRate () const |
Gets the emit rate of the density. | |
float | getEmitTemperatureRate () const |
Gets the emit rate of the temperature. | |
ngl::Vec3 | getLocation () const |
Gets the location of the emitter. | |
float | getSize () const |
Gets the size of the emitter. | |
void | setEmitDensityRate (double _val) |
Sets the density rate of the emitter. | |
void | setEmitTemperatureRate (double _val) |
Sets the temperature rate of the emitter. | |
void | setLocation (const ngl::Vec3 _loc) |
Sets the emitter location. | |
void | setSize (double _val) |
Sets the size of the emitter. | |
Private Attributes | |
float | m_emitDensityRate |
The rate that the density is emitted (Density per Voxel per Second) | |
float | m_emitTemperatureRate |
The rate that the temperature is emitted (Density per Voxel per Second) | |
ngl::Vec3 | m_location |
The location of the emitter in the voxel grid. | |
float | m_size |
The size of the emitter. |
The functions and elements of an Emitter.
Emitter::Emitter | ( | const ngl::Vec3 | _location = ngl::Vec3(0,0,0) , |
const float | _size = 1.0 , |
||
const float | _emitDensityRate = 4.0 , |
||
const float | _emitTemperatureRate = 4.0 |
||
) |
Constructor for Emitter.
[in] | _location | the location of the emitter in the voxel grid domain. |
[in] | _size | the size of the emitter (the radius). |
[in] | _emitDensityRate | the rate in which density is being emitted. |
[in] | _emitTemperatureRate | the rate in which temperature is being emitted. |
1. Initialize the class member variables.
Destructor for Emitter.
1. De-allocate the memory.
float Emitter::getEmitDensityRate | ( | ) | const [inline] |
Gets the emit rate of the density.
float Emitter::getEmitTemperatureRate | ( | ) | const [inline] |
Gets the emit rate of the temperature.
ngl::Vec3 Emitter::getLocation | ( | ) | const [inline] |
Gets the location of the emitter.
float Emitter::getSize | ( | ) | const [inline] |
Gets the size of the emitter.
void Emitter::setEmitDensityRate | ( | double | _val | ) | [inline] |
Sets the density rate of the emitter.
[in] | _val | the value to be set to the density rate of the emitter |
void Emitter::setEmitTemperatureRate | ( | double | _val | ) | [inline] |
Sets the temperature rate of the emitter.
[in] | _val | the value to be set to the temperature rate of the emitter |
void Emitter::setLocation | ( | const ngl::Vec3 | _loc | ) | [inline] |
Sets the emitter location.
[in] | _loc | the vector to be set to the emitter location |
void Emitter::setSize | ( | double | _val | ) | [inline] |
Sets the size of the emitter.
[in] | _val | the value to be set to the size of the emitter |