1 |
//------------------------------------------------------------ |
2 |
//------------------------------------------------------------ |
3 |
// MAGiC |
4 |
// Jean Christophe Cuilli�re et Vincent FRANCOIS |
5 |
// D�partement de G�nie M�canique - UQTR |
6 |
//------------------------------------------------------------ |
7 |
// Le projet MAGIC est un projet de recherche du d�partement |
8 |
// de g�nie m�canique de l'Universit� du Qu�bec � |
9 |
// Trois Rivi�res |
10 |
// Les librairies ne peuvent �tre utilis�es sans l'accord |
11 |
// des auteurs (contact : francois@uqtr.ca) |
12 |
//------------------------------------------------------------ |
13 |
//------------------------------------------------------------ |
14 |
// |
15 |
// mg_segment.h |
16 |
// |
17 |
//------------------------------------------------------------ |
18 |
//------------------------------------------------------------ |
19 |
// COPYRIGHT 2000 |
20 |
// Version du 02/03/2006 � 11H22 |
21 |
//------------------------------------------------------------ |
22 |
//------------------------------------------------------------ |
23 |
#ifndef _MGSEGMENT_ |
24 |
#define _MGSEGMENT_ |
25 |
|
26 |
#ifdef WINDOWS_VERSION |
27 |
#ifdef BUILT_DLL_GEOMETRIE |
28 |
#define DLLPORTGEOMETRIE __declspec(dllexport) |
29 |
#else |
30 |
#define DLLPORTGEOMETRIE __declspec(dllimport) |
31 |
#endif |
32 |
#else |
33 |
#define DLLPORTGEOMETRIE |
34 |
#endif |
35 |
|
36 |
#include "tpl_liste_entite.h" |
37 |
#include "mg_element_maillage.h" |
38 |
#include "mg_noeud.h" |
39 |
#include "ot_reference.h" |
40 |
#include "ot_boite_2d.h" |
41 |
#include "ot_boite_3d.h" |
42 |
|
43 |
const unsigned int IDMG_SEGMENT=200; |
44 |
|
45 |
|
46 |
|
47 |
class DLLPORTGEOMETRIE MG_SEGMENT : public MG_ELEMENT_MAILLAGE, public OT_REFERENCE |
48 |
{ |
49 |
public: |
50 |
MG_SEGMENT(unsigned long num,MG_ELEMENT_TOPOLOGIQUE* topo,class MG_NOEUD *mgnoeud1,class MG_NOEUD *mgnoeud2,int origine,double longue=0.0); |
51 |
MG_SEGMENT(MG_ELEMENT_TOPOLOGIQUE* topo,MG_NOEUD *mgnoeud1,MG_NOEUD *mgnoeud2,int origine,double longue=0.0); |
52 |
MG_SEGMENT(MG_SEGMENT& mdd); |
53 |
virtual MG_SEGMENT* dupliquer(class MG_MAILLAGE *mgmai,long decalage); |
54 |
virtual ~MG_SEGMENT(); |
55 |
virtual int get_type_entite(void); |
56 |
|
57 |
virtual MG_NOEUD* get_noeud1(void); |
58 |
virtual MG_NOEUD* get_noeud2(void); |
59 |
virtual double get_longueur(void); |
60 |
|
61 |
virtual void change_noeud1(MG_NOEUD* mgnoeud,double longue=0.0); |
62 |
virtual void change_noeud2(MG_NOEUD* mgnoeud,double longue=0.0); |
63 |
|
64 |
virtual class BOITE_2D get_boite_2D(double periodeu,double periodev); |
65 |
virtual class BOITE_3D get_boite_3D(void); |
66 |
virtual int get_dimension(void); |
67 |
virtual void enregistrer(std::ostream& o); |
68 |
|
69 |
TPL_LISTE_ENTITE<class MG_TRIANGLE*> *get_lien_triangle(void); |
70 |
TPL_LISTE_ENTITE<class MG_QUADRANGLE*> *get_lien_quadrangle(void); |
71 |
|
72 |
virtual void extrapoler_solution_noeud(void); |
73 |
virtual void change_dimension_topo_null(int num); |
74 |
virtual int get_dimension_topo_null(void); |
75 |
|
76 |
virtual bool get_distance_metrique(double *l); |
77 |
virtual void change_distance_metrique(double val); |
78 |
protected: |
79 |
void calcule_longueur(void); |
80 |
|
81 |
class MG_NOEUD* noeud1; |
82 |
class MG_NOEUD* noeud2; |
83 |
double longueur; |
84 |
int dimension; |
85 |
TPL_LISTE_ENTITE<class MG_TRIANGLE*> triangle; |
86 |
TPL_LISTE_ENTITE<class MG_QUADRANGLE*> quadrangle; |
87 |
bool distance_metrique_valide; |
88 |
double distance_metrique; |
89 |
}; |
90 |
|
91 |
|
92 |
|
93 |
|
94 |
|
95 |
|
96 |
#endif |
97 |
|
98 |
|
99 |
|