Code_TYMPAN
4.2.0
Industrial site acoustic simulation
|
#include <DefaultEngine.h>
Public Member Functions | |
DefaultEngine () | |
Constructors. More... | |
DefaultEngine (Scene *_scene, std::vector< Source > *_sources, Solver *_solver, Scene *_recepteurs) | |
DefaultEngine (const DefaultEngine &other) | |
Copy constructor. More... | |
virtual | ~DefaultEngine () |
Destructor. More... | |
virtual bool | process () |
If implemented, process and return true if success. More... | |
virtual void | runStructureBenchmark () |
If implemented, run a benchmark for the engine. More... | |
Ray * | genRay () |
Create rays from the sources. More... | |
Public Member Functions inherited from Engine | |
Engine () | |
Default constructor. More... | |
Engine (Scene *_scene, std::vector< Source > *_sources, Solver *_solver, Scene *_recepteurs) | |
Constructor. More... | |
Engine (const Engine &other) | |
Copy constructor. More... | |
virtual | ~Engine () |
Destructor. More... | |
Scene * | getScene () |
Get the Scene. More... | |
void | setScene (Scene *_scene) |
Set the Scene. More... | |
std::vector< Source > * | getSources () |
Get the Sources. More... | |
void | setSources (std::vector< Source > *_sources) |
Set the Sources. More... | |
Solver * | getSolver () |
Get the Solver. More... | |
void | setSolver (Solver *_solver) |
Set the Solver. More... | |
virtual unsigned long long int | getRayCounter () |
Protected Member Functions | |
void | searchForReceptor (const decimal &tmin, Ray *r) |
Search if a ray intersects a receptor before traveling a tmin distance (NB: this is the only place in the code where a ray is added to the solver's list of valid rays) More... | |
void | initialReceptorTargeting () |
Initialize the rays treatment stack by a loop on the receptors. More... | |
void | copyRayAndAddToStack (Ray *r) |
Copy a ray and use its last event to generate a response to use as the copy's direction (used to handle the generation of rays by diffraction events) More... | |
virtual bool | traitementRay (Ray *r, std::list< validRay > &result) |
Ray treatment method. More... | |
Protected Attributes | |
std::stack< Ray *, std::deque< Ray * > > | pile_traitement |
Treatment stack containing the rays to treat. More... | |
unsigned long long int | nbRayonsTraites |
Treated rays number. More... | |
Protected Attributes inherited from Engine | |
Scene * | scene |
Pointer to the scene. More... | |
std::vector< Source > * | sources |
Pointer to all the receptors. More... | |
Scene * | recepteurs |
Pointer to all the sources. More... | |
Solver * | solver |
Pointer to the solver. More... | |
unsigned long long int | rayCounter |
Ray counter. More... | |
Default Engine class.
Definition at line 25 of file DefaultEngine.h.
|
inline |
Constructors.
Definition at line 30 of file DefaultEngine.h.
|
inline |
Definition at line 32 of file DefaultEngine.h.
|
inline |
Copy constructor.
Definition at line 35 of file DefaultEngine.h.
|
inlinevirtual |
Destructor.
Definition at line 43 of file DefaultEngine.h.
|
inlineprotected |
Copy a ray and use its last event to generate a response to use as the copy's direction (used to handle the generation of rays by diffraction events)
r | Return modified ray |
Definition at line 209 of file DefaultEngine.h.
Ray * DefaultEngine::genRay | ( | ) |
Create rays from the sources.
Definition at line 129 of file DefaultEngine.cpp.
|
inlineprotected |
Initialize the rays treatment stack by a loop on the receptors.
Definition at line 103 of file DefaultEngine.h.
|
virtual |
If implemented, process and return true if success.
Reimplemented from Engine.
Reimplemented in DefaultCurvRayEngine.
Definition at line 61 of file DefaultEngine.cpp.
|
virtual |
If implemented, run a benchmark for the engine.
Reimplemented from Engine.
Definition at line 226 of file DefaultEngine.cpp.
|
inlineprotected |
Search if a ray intersects a receptor before traveling a tmin distance (NB: this is the only place in the code where a ray is added to the solver's list of valid rays)
tmin | maximum distance the ray can travel before hiting a receptor for the intersection to be considered valid |
r | The ray |
Definition at line 59 of file DefaultEngine.h.
Ray treatment method.
r | Ray to treat |
result | Updated valid rays list |
Reimplemented in DefaultCurvRayEngine.
Definition at line 154 of file DefaultEngine.cpp.
|
protected |
Treated rays number.
Definition at line 235 of file DefaultEngine.h.
Treatment stack containing the rays to treat.
Definition at line 233 of file DefaultEngine.h.