ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/REPOS_ERICCA/magic/lib/geometrie/src/mg_solution.h
Revision: 253
Committed: Tue Jul 13 19:40:46 2010 UTC (14 years, 10 months ago) by francois
Content type: text/plain
File size: 2848 byte(s)
Log Message:
changement de hiearchie et utilisation de ccmake + mise a jour

File Contents

# User Rev Content
1 5 //------------------------------------------------------------
2     //------------------------------------------------------------
3     // MAGiC
4 francois 174 // Jean Christophe Cuilli�re et Vincent FRANCOIS
5     // D�partement de G�nie M�canique - UQTR
6 5 //------------------------------------------------------------
7 francois 174 // 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 5 // des auteurs (contact : francois@uqtr.ca)
12     //------------------------------------------------------------
13     //------------------------------------------------------------
14     //
15     // mg_solution.h
16     //
17     //------------------------------------------------------------
18     //------------------------------------------------------------
19     // COPYRIGHT 2000
20 francois 174 // Version du 02/03/2006 � 11H22
21 5 //------------------------------------------------------------
22     //------------------------------------------------------------
23     #ifndef __MGSOLUTION_
24     #define __MGSOLUTION_
25    
26    
27     #ifdef WINDOWS_VERSION
28     #ifdef BUILT_DLL_GEOMETRIE
29     #define DLLPORTGEOMETRIE __declspec(dllexport)
30     #else
31     #define DLLPORTGEOMETRIE __declspec(dllimport)
32     #endif
33     #else
34     #define DLLPORTGEOMETRIE
35     #endif
36    
37    
38     #ifdef BORLANDCPP
39     #include <map.h>
40     #include <set.h>
41     #else
42     #include <map>
43     #include <set>
44     #endif
45    
46 foucault 27 // necessaire pour definir le type FILE dans GCC
47     #include <stdio.h>
48    
49 5 #include "mg_identificateur.h"
50    
51    
52     const unsigned int SOL_EXISTANTE=0;
53    
54 francois 174 #define ENTITE_NOEUD 1
55     #define ENTITE_SEGMENT 2
56     #define ENTITE_TRIANGLE 3
57     #define ENTITE_TETRA 4
58 5
59    
60     DLLPORTGEOMETRIE std::ostream& operator << (std::ostream& o,class MG_SOLUTION& sol);
61    
62    
63     class DLLPORTGEOMETRIE MG_SOLUTION : public MG_IDENTIFICATEUR
64     {
65     public:
66 francois 174 MG_SOLUTION(class MG_MAILLAGE *mai,int nb,char* chemin,int code,std::string nomsol,int entite=ENTITE_NOEUD);
67     MG_SOLUTION(unsigned long num,MG_MAILLAGE *mai,int nb,char* chemin,int code,std::string nomsol,int entite=ENTITE_NOEUD);
68 5 virtual ~MG_SOLUTION();
69    
70     double lire(int i,int j);
71     void ecrire(int i,int j,double val);
72     void active_solution(int num);
73     void change_legende(int num,std::string val);
74     std::string get_legende(int num);
75     int get_nb_champ(void);
76     MG_MAILLAGE* get_maillage(void);
77     double get_legende_min(void);
78     double get_legende_max(void);
79     void efface(void);
80     std::string get_nom(void);
81 francois 174 int get_type_solution(void);
82 5
83     virtual void enregistrer(std::ostream& o);
84    
85     friend std::ostream& operator << (std::ostream& o,MG_SOLUTION& maillage);
86    
87     private:
88     char *nom_fichier;
89     int nb_champs;
90     FILE* in;
91     MG_MAILLAGE* mgmai;
92     double solmin;
93     double solmax;
94     std::string* legende;
95     std::string nomsolution;
96 francois 174 int typeentite;
97 5 };
98    
99    
100    
101     #endif
102    
103