Code_TYMPAN
4.4.0
Industrial site acoustic simulation
Tympan
gui
gl
TYRectangularMaillageGraphic.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) <2012-2024> <EDF-DTG> <FRANCE>
3
* This file is part of Code_TYMPAN (R).
4
* Code_TYMPAN (R) is free software: you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation, either version 3 of the License, or
7
* (at your option) any later version.
8
* Code_TYMPAN (R) is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11
* See the GNU General Public License for more details.
12
* You should have received a copy of the GNU General Public License along
13
* with Code_TYMPAN (R). If not, see <https://www.gnu.org/licenses/>.
14
*/
15
27
#ifndef __TY_RECTANGULAR_MAILLAGE_GRAPHIC__
28
#define __TY_RECTANGULAR_MAILLAGE_GRAPHIC__
29
30
#include "
Tympan/gui/gl/TYRenderContext.h
"
31
#if _MSC_VER > 1000
32
#pragma once
33
#endif
// _MSC_VER > 1000
34
35
#include "
Tympan/models/business/TYDefines.h
"
36
#include "
TYElementGraphic.h
"
37
38
#include "
Tympan/models/business/TYMaillage.h
"
39
44
class
TYRectangularMaillageGraphic
:
public
TYElementGraphic
45
{
46
TY_DECL_METIER_GRAPHIC
(
TYRectangularMaillage
)
47
48
// Methodes
49
public
:
50
/* Enum mode de rendu du maillage */
51
enum
RenderingMode
52
{
53
RENDER_SURF
,
54
RENDER_LINES
,
55
RENDER_MIXED
56
}
_Rendering
;
57
61
TYRectangularMaillageGraphic
(
TYRectangularMaillage
* pElement);
62
66
virtual
~TYRectangularMaillageGraphic
();
67
75
virtual
void
update
(
bool
force =
false
);
76
84
virtual
void
display
(
TYRenderContext
& renderContext);
85
89
virtual
OBox
computeBoundingBox
()
const
;
90
91
virtual
void
setRendering
(
int
mode)
92
{
93
_Rendering
= (
RenderingMode
)mode;
94
};
95
96
private
:
100
int
nextPoint
(
const
TYTabLPPointCalcul
* pPtsCalcul,
const
int
& index1,
const
int
& index2);
101
102
protected
:
103
std::vector<MTriangle>
_mesh
;
104
std::vector<MPoint>
_isoCurve
;
105
106
double
_scalarX
;
107
double
_scalarY
;
108
double
_scalarW
;
109
double
_scalarH
;
110
double
_panelW
;
111
double
_panelH
;
112
113
virtual
void
displaySurface
(
TYRenderContext
& renderContext);
114
virtual
void
displayLines
(
TYRenderContext
& renderContext,
bool
invertColors =
false
);
115
virtual
void
displayMixed
(
TYRenderContext
& renderContext);
116
};
117
118
#endif
// __TY_RECTANGULAR_MAILLAGE_GRAPHIC__
TYDefines.h
TYTabLPPointCalcul
std::vector< LPTYPointCalcul > TYTabLPPointCalcul
Collection de pointeurs de TYPointCalcul.
Definition:
TYDefines.h:358
TYElementGraphic.h
Representation graphique d'un element de base (fichier header)
TY_DECL_METIER_GRAPHIC
#define TY_DECL_METIER_GRAPHIC(classname)
Definition:
TYElementGraphic.h:41
TYMaillage.h
TYRenderContext.h
Contexte de rendu utilisé par les fonctions d'affichage.
OBox
The box class.
Definition:
3d.h:1346
TYElementGraphic
classe graphique pour un element de base
Definition:
TYElementGraphic.h:63
TYRectangularMaillageGraphic
classe graphique pour un maillage rectangulaire
Definition:
TYRectangularMaillageGraphic.h:45
TYRectangularMaillageGraphic::setRendering
virtual void setRendering(int mode)
Definition:
TYRectangularMaillageGraphic.h:91
TYRectangularMaillageGraphic::_scalarW
double _scalarW
Definition:
TYRectangularMaillageGraphic.h:108
TYRectangularMaillageGraphic::_isoCurve
std::vector< MPoint > _isoCurve
Definition:
TYRectangularMaillageGraphic.h:104
TYRectangularMaillageGraphic::displaySurface
virtual void displaySurface(TYRenderContext &renderContext)
Definition:
TYRectangularMaillageGraphic.cpp:196
TYRectangularMaillageGraphic::_panelH
double _panelH
Definition:
TYRectangularMaillageGraphic.h:111
TYRectangularMaillageGraphic::computeBoundingBox
virtual OBox computeBoundingBox() const
Definition:
TYRectangularMaillageGraphic.cpp:79
TYRectangularMaillageGraphic::~TYRectangularMaillageGraphic
virtual ~TYRectangularMaillageGraphic()
Definition:
TYRectangularMaillageGraphic.cpp:59
TYRectangularMaillageGraphic::display
virtual void display(TYRenderContext &renderContext)
Definition:
TYRectangularMaillageGraphic.cpp:111
TYRectangularMaillageGraphic::_panelW
double _panelW
Definition:
TYRectangularMaillageGraphic.h:110
TYRectangularMaillageGraphic::_Rendering
enum TYRectangularMaillageGraphic::RenderingMode _Rendering
TYRectangularMaillageGraphic::displayMixed
virtual void displayMixed(TYRenderContext &renderContext)
Definition:
TYRectangularMaillageGraphic.cpp:374
TYRectangularMaillageGraphic::update
virtual void update(bool force=false)
Definition:
TYRectangularMaillageGraphic.cpp:61
TYRectangularMaillageGraphic::RenderingMode
RenderingMode
Definition:
TYRectangularMaillageGraphic.h:52
TYRectangularMaillageGraphic::RENDER_MIXED
@ RENDER_MIXED
Definition:
TYRectangularMaillageGraphic.h:55
TYRectangularMaillageGraphic::RENDER_LINES
@ RENDER_LINES
Definition:
TYRectangularMaillageGraphic.h:54
TYRectangularMaillageGraphic::RENDER_SURF
@ RENDER_SURF
Definition:
TYRectangularMaillageGraphic.h:53
TYRectangularMaillageGraphic::_scalarX
double _scalarX
Definition:
TYRectangularMaillageGraphic.h:106
TYRectangularMaillageGraphic::_scalarH
double _scalarH
Definition:
TYRectangularMaillageGraphic.h:109
TYRectangularMaillageGraphic::_scalarY
double _scalarY
Definition:
TYRectangularMaillageGraphic.h:107
TYRectangularMaillageGraphic::displayLines
virtual void displayLines(TYRenderContext &renderContext, bool invertColors=false)
Definition:
TYRectangularMaillageGraphic.cpp:325
TYRectangularMaillageGraphic::_mesh
std::vector< MTriangle > _mesh
Definition:
TYRectangularMaillageGraphic.h:103
TYRectangularMaillageGraphic::nextPoint
int nextPoint(const TYTabLPPointCalcul *pPtsCalcul, const int &index1, const int &index2)
Definition:
TYRectangularMaillageGraphic.cpp:380
TYRectangularMaillageGraphic::TYRectangularMaillageGraphic
TYRectangularMaillageGraphic(TYRectangularMaillage *pElement)
Definition:
TYRectangularMaillageGraphic.cpp:34
TYRectangularMaillage
Classe de definition d'un maillage rectangulaire.
Definition:
TYRectangularMaillage.h:39
TYRenderContext
Definition:
TYRenderContext.h:45
Generated on Mon Feb 2 2026 12:03:42 for Code_TYMPAN by
1.9.1