73 int nbTrajectsForOneSource = 0;
74 int nbTrajectsTotal = 0;
78 "Overwriting Acccelerator solver parameter to 1 (grid accelerating structure)");
109 for (
unsigned int i = 0; i < aproblem.
nsources(); i++)
116 nbTrajectsForOneSource = 0;
118 for (
unsigned int j = 0; j < aproblem.
nreceptors(); j++)
122 nbTrajectsForOneSource++;
135 if (keepRays ==
true)
149 const string& sourceVolumeId)
173 for (
unsigned int i = 0; i < triangles.size(); i++)
175 pts[0] = nodes[triangles[i].n[0]];
176 pts[1] = nodes[triangles[i].n[1]];
177 pts[2] = nodes[triangles[i].n[2]];
186 SI.
material = triangles[i].made_of.get();
208 for (
unsigned int i = 0; i <
_tabPolygon.size(); i++)
212 unsigned int a, b,
c;
215 _scene->addVertex(pos, a);
218 _scene->addVertex(pos, b);
std::vector< acoustic_path * > tab_acoustic_path
static void computeNormal(OPoint3D *pts, int nbPts, OVector3D &normal)
Computes the normal of the list of points.
virtual void warning(const char *message,...)
static OMessageManager * get()
Class to define a segment.
Slave threads collection.
void begin(unsigned int count)
Begin solver.
This class mainly define a mesh (list of Shape) used by the Simulation object.
Build the acoustic path for the 9613 family solvers.
Building class of the faces list.
virtual void selectFaces(std::deque< TYSIntersection > &tabIntersect, const std::vector< TYStructSurfIntersect > &tabPolygon, const OSegment3D &rayon, const string &sourceVolumeId)
Build the array of intersections.
virtual void clearTabTrajets()=0
Clear the specific array of TYTrajet depending on the solver.
std::vector< TYStructSurfIntersect > _tabPolygon
Vector of TYStructSurfIntersect.
std::unique_ptr< TYFaceSelector > _faceSelector
Pointer to the TYFaceSelector.
std::unique_ptr< TYAcousticPathFinder > make_path_finder()
TYAcousticPathFinder builder.
virtual void addNewTaskForOneTrajetSrcRcp(const tympan::AcousticProblemModel &aproblem, unsigned int src_index, unsigned int rcp_index, int nbTrajetsForThisSource, int nNbTrajets)=0
Instanciate a new task to compute a Trajet.
std::unique_ptr< Scene > _scene
Pointer to the Scene.
virtual ~TYSolver()
Destructor.
virtual void buildAcousticModel()=0
Build the acoustic model.
bool appendTriangleToScene()
Convertion des triangles Tympan en primitives utilisables par ray tracer.
void selectFaces(std::deque< TYSIntersection > &tabIntersect, const OSegment3D &rayon, const string &sourceVolumeId)
Delegate to _faceSelector the build of the array of intersections.
virtual void buildResultsMatrix(int nSourceTrajetsNumber, tympan::SpectrumMatrix &matrix)=0
Build the matrix of the results for a given source and all the receptors These results are the result...
std::unique_ptr< TYAcousticPathFinder > _acousticPathFinder
Pointer to the TYAcousticPathFinder.
virtual bool solve(const tympan::AcousticProblemModel &aproblem, tympan::AcousticResultModel &aresult, tympan::LPSolverConfiguration configuration)
Launch the resolution and get the results.
virtual void deleteTrajets()=0
Delete all the Trajets.
virtual void displayRaysInGUI(tab_acoustic_path &tabRays)=0
Keep rays in tab in order to display them in GUI.
void init()
Initialize solver This method must be called after instantiation of a solver.
bool buildCalcStruct(const tympan::AcousticProblemModel &aproblem)
TYFaceSelector * getFaceSelector()
Get the face selector.
std::unique_ptr< TYFaceSelector > make_face_selector()
TYFaceSelector builder.
virtual void initAcousticModel()=0
Initialize the acoustic model.
3D vector Vector defined with 3 float numbers
Describes the ground material, a specific AcousticBuildingMaterial.
Class to describe the acoustic problem.
size_t nsources() const
Return the total number of sources.
size_t nreceptors() const
Return the total number of receptors.
const nodes_pool_t & nodes() const
Return array of nodes.
const triangle_pool_t & triangles() const
Return array of triangles.
Contains the results of the model solved.
SpectrumMatrix & get_data()
Return the results matrix.
tab_acoustic_path & get_path_data()
Return the array of the acoustic paths.
static void set(LPSolverConfiguration config)
Set a configuration.
static LPSolverConfiguration get()
Get the configuration.
Spectrum matrix N*M used to store results. N is the number of receptors. M is the number of sources.
void resize(size_t nb_receptors, size_t nb_sources)
Resize the matrix (data is cleared)
vec3 OPoint3Dtovec3(const OPoint3D &_p)
Converts a OPoint3D to vec3.
boost::shared_ptr< SolverConfiguration > LPSolverConfiguration
std::deque< Point > nodes_pool_t
std::deque< AcousticTriangle > triangle_pool_t
Array of AcousticTriangle.
Describe surface intersections.
tympan::AcousticMaterialBase * material
Reference to a material.
string volume_id
Volume id.
TabPoint3D tabPoint
Array of points used for the preselection.
boost::shared_ptr< tympan::AcousticFaceGeomData > pFaceGeomData
OVector3D normal
Normal vector to a face.