|
Code_TYMPAN
4.4.0
Industrial site acoustic simulation
|
Diffraction class Event. More...
#include <Diffraction.h>


Public Member Functions | |
| Diffraction (const vec3 &position=vec3(0.0, 0.0, 0.0), const vec3 &incomingDirection=vec3(0.0, 0.0, 0.0), Cylindre *c=NULL) | |
| Constructor. More... | |
| Diffraction (const Diffraction &other) | |
| Copy constructor. More... | |
| virtual | ~Diffraction () |
| Destructor. More... | |
| virtual void | setNbResponseLeft (int _nbResponseLeft) |
| Set the number of remaining rays to launch. More... | |
| virtual bool | getResponse (vec3 &r, bool force=false) |
| Computes the next response of the event in function of the number of responses left. More... | |
| void | setAngleOuverture (decimal angle) |
| Set the aperture angle of the cone of Keller. More... | |
| decimal | getAngleOuverture () |
| Get the aperture angle of the cone of Keller. More... | |
| decimal | getDeltaTheta () const |
| Get the angle between 2 consecutive responses. More... | |
| virtual double | getAngle () |
| Get the angle between the incident ray and the diffraction edge. More... | |
| virtual bool | generateTest (std::vector< vec3 > &succededTest, std::vector< vec3 > &failTest, unsigned int nbResponses) |
| virtual const Repere & | getRepere () const |
| Get the local frame. More... | |
Public Member Functions inherited from Event | |
| Event (const vec3 &position=vec3(0.0, 0.0, 0.0), const vec3 &incomingDirection=vec3(0.0, 0.0, 0.0), Shape *_shape=NULL) | |
| Default constructor. More... | |
| Event (const Event &other) | |
| Copy constructor. More... | |
| virtual | ~Event () |
| Destructor. More... | |
| const vec3 & | getPosition () const |
| Return a reference to the event location point. More... | |
| void | setPosition (const vec3 &_pos) |
| Set a new point to the event. More... | |
| vec3 | getIncomingDirection () |
| Return the direction of the incoming vector. More... | |
| void | setIncomingDirection (const vec3 &_from) |
| Set a new incoming vector. More... | |
| bool | isReponseLeft () |
| Return true if it remains rays to launch. More... | |
| int | getNbResponseLeft () |
| Return the number of remaining rays to launch. More... | |
| virtual int | getInitialNbResponseLeft () const |
| Return the number of rays to launch after event. More... | |
| Shape * | getShape () |
| Return the primitive of the impact. More... | |
| const Shape * | getShape () const |
| void | setShape (Shape *_shape) |
| Set the impacted primitive of the event. More... | |
| virtual bool | isAcceptableResponse (vec3 &test) |
| Return true if the ray direction vector in response of the event is acceptable. More... | |
| virtual bool | generateResponse (std::vector< vec3 > &responses, unsigned int nbResponses) |
| virtual bool | appendTarget (vec3 target, bool force=false) |
| virtual int | getType () const |
| Return the event type. More... | |
| virtual void | setType (const typeevent &_type) |
| Added by DTh to make possible simple test of rays. More... | |
| virtual double | getAngle () const |
| Get incident angle. More... | |
| const decimal | distance (const Event &other) const |
| Return distance from another event. More... | |
Public Member Functions inherited from Base | |
| Base () | |
| Default constructor. More... | |
| Base (const Base &other) | |
| Copy constructor. More... | |
| virtual | ~Base () |
| Destructor. More... | |
| std::string | getName () |
| Get the name of the object. More... | |
| void | setName (const std::string &_name) |
| Set the name of the object. More... | |
Public Attributes | |
| bool(* | responseValidator )(const vec3 &, const vec3 &, const vec3 &, vec3 &) |
| Filter generated response (or not) More... | |
| void(* | getTheta )(const decimal &, const decimal &, const decimal &, decimal &) |
Protected Member Functions | |
| void | buildRepere () |
| Build local frame. More... | |
| void | computeAngle () |
| Compute the angle between the incident ray and the diffraction edge. More... | |
| void | computeDTheta () |
| Compute the angle step between two responses in function of the aperture angle and the number of responses left. More... | |
Protected Attributes | |
| Repere | localRepere |
| Local frame. More... | |
| decimal | angleOuverture |
| Angle formed by the two faces of the diffraction edge. More... | |
| decimal | angleArrive |
| Incident ray angle. More... | |
| decimal | delta_theta |
| Angle step between two rays to send. More... | |
| vec3 | N1 |
| Face 1 normal. More... | |
| vec3 | N2 |
| Face 2 normal. More... | |
Protected Attributes inherited from Event | |
| vec3 | pos |
| Location point of the event. More... | |
| vec3 | from |
| Direction vector of the incoming ray. More... | |
| int | nbResponseLeft |
| Number of remaining rays to launch. More... | |
| int | initialNbResponse |
| Number of rays to launch after event. More... | |
| Sampler * | sampler |
| Pointer to a Sampler. More... | |
| Shape * | shape |
| The impact primitive. More... | |
| typeevent | type |
| Event type. More... | |
Protected Attributes inherited from Base | |
| std::string | name |
| Each instantiated object may be named. More... | |
Diffraction class Event.
Definition at line 30 of file Diffraction.h.
| Diffraction::Diffraction | ( | const vec3 & | position = vec3(0.0, 0.0, 0.0), |
| const vec3 & | incomingDirection = vec3(0.0, 0.0, 0.0), |
||
| Cylindre * | c = NULL |
||
| ) |
Constructor.
Definition at line 87 of file Diffraction.cpp.

| Diffraction::Diffraction | ( | const Diffraction & | other | ) |
Copy constructor.
Definition at line 125 of file Diffraction.cpp.

|
inlinevirtual |
Destructor.
Definition at line 39 of file Diffraction.h.
|
protected |
Build local frame.
Definition at line 188 of file Diffraction.cpp.

|
protected |
Compute the angle between the incident ray and the diffraction edge.
Definition at line 215 of file Diffraction.cpp.


|
inlineprotected |
Compute the angle step between two responses in function of the aperture angle and the number of responses left.
Definition at line 123 of file Diffraction.h.

|
virtual |
Reimplemented from Event.
Definition at line 230 of file Diffraction.cpp.

|
inlinevirtual |
Get the angle between the incident ray and the diffraction edge.
Definition at line 90 of file Diffraction.h.

|
inline |
Get the aperture angle of the cone of Keller.
Definition at line 74 of file Diffraction.h.
|
inline |
Get the angle between 2 consecutive responses.
Definition at line 82 of file Diffraction.h.
|
inlinevirtual |
Get the local frame.
Definition at line 97 of file Diffraction.h.
|
virtual |
Computes the next response of the event in function of the number of responses left.
Reimplemented from Event.
Definition at line 138 of file Diffraction.cpp.


|
inline |
Set the aperture angle of the cone of Keller.
Definition at line 65 of file Diffraction.h.

|
inlinevirtual |
Set the number of remaining rays to launch.
Reimplemented from Event.
Definition at line 41 of file Diffraction.h.


|
protected |
Incident ray angle.
Definition at line 132 of file Diffraction.h.
|
protected |
Angle formed by the two faces of the diffraction edge.
Definition at line 131 of file Diffraction.h.
|
protected |
Angle step between two rays to send.
Definition at line 134 of file Diffraction.h.
| void(* Diffraction::getTheta) (const decimal &, const decimal &, const decimal &, decimal &) |
Get the angle of the next response around Keller's cone. (returns only angles that result in a response pointing outside the obstacle)
Definition at line 60 of file Diffraction.h.
|
protected |
Local frame.
Definition at line 129 of file Diffraction.h.
|
protected |
Face 1 normal.
Definition at line 136 of file Diffraction.h.
|
protected |
Face 2 normal.
Definition at line 137 of file Diffraction.h.
| bool(* Diffraction::responseValidator) (const vec3 &, const vec3 &, const vec3 &, vec3 &) |
Filter generated response (or not)
Definition at line 56 of file Diffraction.h.