Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023 #ifndef DEFINE_HXX
00024 #define DEFINE_HXX
00025
00026 #include <stdio.h>
00027 #include <iostream>
00028 #include <string>
00029 #include <assert.h>
00030
00031
00032 #include <hdf5.h>
00033
00034 namespace med_2_3 {
00035 extern "C" {
00036 #include <med.h>
00037 med_err MEDfieldComputingStepInfo(const med_idt fid,
00038 const char * const fieldname,
00039 const int csit,
00040 med_int * const numdt,
00041 med_int * const numit,
00042 med_float * const dt);
00043
00044 med_err MEDmeshEntityFamilyNumberRd(const med_idt fid,
00045 const char* const meshname,
00046 const med_int numdt,
00047 const med_int numit,
00048 const med_entity_type entitype,
00049 const med_geometry_type geotype,
00050 med_int * const number);
00051
00052 med_err MEDmeshEntityNumberRd(const med_idt fid,
00053 const char* const meshname,
00054 const med_int numdt,
00055 const med_int numit,
00056 const med_entity_type entitype,
00057 const med_geometry_type geotype,
00058 med_int * const number);
00059
00060 med_err MEDfieldCr( const med_idt fid,
00061 const char * const fieldname,
00062 const med_field_type fieldtype,
00063 const med_int nbofcomponent,
00064 const char * const componentname,
00065 const char * const componentunit,
00066 const char * const dtunit,
00067 const char * const meshname);
00068 }
00069 }
00070
00071 namespace MED_EN {
00072 extern "C" {
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083 #ifdef MED_NONE
00084 #undef MED_NONE
00085 #endif
00086 #ifdef MED_POINT1
00087 #undef MED_POINT1
00088 #endif
00089 #ifdef MED_SEG2
00090 #undef MED_SEG2
00091 #endif
00092 #ifdef MED_SEG3
00093 #undef MED_SEG3
00094 #endif
00095 #ifdef MED_TRIA3
00096 #undef MED_TRIA3
00097 #endif
00098 #ifdef MED_QUAD4
00099 #undef MED_QUAD4
00100 #endif
00101 #ifdef MED_TRIA6
00102 #undef MED_TRIA6
00103 #endif
00104 #ifdef MED_QUAD8
00105 #undef MED_QUAD8
00106 #endif
00107 #ifdef MED_TETRA4
00108 #undef MED_TETRA4
00109 #endif
00110 #ifdef MED_PYRA5
00111 #undef MED_PYRA5
00112 #endif
00113 #ifdef MED_PENTA6
00114 #undef MED_PENTA6
00115 #endif
00116 #ifdef MED_HEXA8
00117 #undef MED_HEXA8
00118 #endif
00119 #ifdef MED_TETRA10
00120 #undef MED_TETRA10
00121 #endif
00122 #ifdef MED_PYRA13
00123 #undef MED_PYRA13
00124 #endif
00125 #ifdef MED_PENTA15
00126 #undef MED_PENTA15
00127 #endif
00128 #ifdef MED_HEXA20
00129 #undef MED_HEXA20
00130 #endif
00131 #ifdef MED_POLYGON
00132 #undef MED_POLYGON
00133 #endif
00134 #ifdef MED_POLYHEDRA
00135 #undef MED_POLYHEDRA
00136 #endif
00137 #ifdef MED_ALL_ELEMENTS
00138 #undef MED_ALL_ELEMENTS
00139 #endif
00140
00141 typedef long medGeometryElement;
00142 const medGeometryElement MED_NONE = 0;
00143 const medGeometryElement MED_POINT1 = 1;
00144 const medGeometryElement MED_SEG2 = 102;
00145 const medGeometryElement MED_SEG3 = 103;
00146 const medGeometryElement MED_TRIA3 = 203;
00147 const medGeometryElement MED_QUAD4 = 204;
00148 const medGeometryElement MED_TRIA6 = 206;
00149 const medGeometryElement MED_QUAD8 = 208;
00150 const medGeometryElement MED_TETRA4 = 304;
00151 const medGeometryElement MED_PYRA5 = 305;
00152 const medGeometryElement MED_PENTA6 = 306;
00153 const medGeometryElement MED_HEXA8 = 308;
00154 const medGeometryElement MED_TETRA10 = 310;
00155 const medGeometryElement MED_PYRA13 = 313;
00156 const medGeometryElement MED_PENTA15 = 315;
00157 const medGeometryElement MED_HEXA20 = 320;
00158 const medGeometryElement MED_POLYGON = 400;
00159 const medGeometryElement MED_POLYHEDRA = 500;
00160 const medGeometryElement MED_ALL_ELEMENTS = 999;
00161
00162 typedef long medEntityMesh;
00163 const medEntityMesh MED_CELL = 0;
00164 const medEntityMesh MED_FACE = 1;
00165 const medEntityMesh MED_EDGE = 2;
00166 const medEntityMesh MED_NODE = 3;
00167 const medEntityMesh MED_ALL_ENTITIES = 4;
00168
00169 typedef long medModeSwitch;
00170 const medModeSwitch MED_FULL_INTERLACE = 0;
00171 const medModeSwitch MED_NO_INTERLACE = 1;
00172 const medModeSwitch MED_NO_INTERLACE_BY_TYPE = 2;
00173 const medModeSwitch MED_UNDEFINED_INTERLACE = 3;
00174
00175 typedef long medConnectivity;
00176 const medConnectivity MED_NODAL = 0;
00177 const medConnectivity MED_DESCENDING = 1;
00178
00179 typedef enum {MED_CARTESIAN, MED_POLAR, MED_BODY_FITTED} med_grid_type;
00180
00181
00182 typedef enum {RDONLY,WRONLY,RDWR} med_mode_acces;
00183
00184 typedef enum {ASCENDING=7,DESCENDING=77} med_sort_direc;
00185
00186 typedef enum {MED_REEL64=6, MED_INT32=24,MED_INT64=26, MED_UNDEFINED_TYPE=0} med_type_champ;
00187
00188
00189
00190
00191
00192 typedef enum {MED_CART, MED_CYL, MED_SPHER} med_repere;
00193
00194 typedef enum {MED_FAUX, MED_VRAI} med_booleen ;
00195
00196 typedef enum {MED_GROUPE, MED_ATTR, MED_FAMILLE} med_dim_famille;
00197
00198 typedef enum {MED_COMP, MED_DTYPE} med_dim_champ;
00199
00200 typedef enum {MED_HDF_VERSION, MED_VERSION, MED_FICH_DES} med_fich_info;
00201
00202
00203
00204
00205
00206
00207
00208
00209
00210
00211
00212 #if defined(SUN4SOL2) || defined(PCLINUX) || defined(PCLINUX64_32) || defined(OSF1_32) || defined(IRIX64_32) || defined(RS6000)
00213
00214
00215
00216
00217
00218 typedef hsize_t med_size;
00219 typedef hssize_t med_ssize;
00220
00221 typedef herr_t med_err;
00222
00223
00224 typedef int med_int;
00225 typedef double med_float;
00226 #endif
00227
00228 #if defined(HP9000)
00229
00230 typedef hsize_t med_size;
00231 typedef hssize_t med_ssize;
00232
00233 typedef herr_t med_err;
00234
00235
00236 typedef int med_int;
00237 typedef double med_float;
00238 #endif
00239
00240 #if defined(IRIX64) || defined(OSF1) || defined(VPP5000) || defined(PCLINUX64)
00241
00242
00243
00244 typedef hsize_t med_size;
00245 typedef hssize_t med_ssize;
00246
00247 typedef herr_t med_err;
00248
00249
00250 typedef long med_int;
00251 typedef double med_float;
00252 #endif
00253
00254
00255 #if defined(PPRO_NT)
00256
00257 typedef hsize_t med_size;
00258 typedef hssize_t med_ssize;
00259
00260 typedef herr_t med_err;
00261
00262
00263 typedef int med_int;
00264 typedef double med_float;
00265 #endif
00266
00267
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283 }
00284
00285
00286 const int FRACT_ALGO = 10;
00287 const int MAX_LOOP = 200;
00288
00289
00290
00291
00292
00293
00294
00295 const int MED_CLOSED = 0;
00296 const int MED_OPENED = 1;
00297 const int MED_INVALID = -1;
00298 const int MED_ERROR = -1;
00299 const int MED_VALID = 0;
00300
00301
00302
00308
00309
00310
00311
00312
00313 const int longueur_string = 100;
00314 const double PRECISION = 0.0000001;
00315 const int MED_UNDEFINED = -1;
00316
00317
00318
00319
00320
00321
00322
00323 const int P1 = 0;
00324 const int pseudo_P2 = 1;
00325 const int trilineaire = 2;
00326 const int P2_adapte = 3;
00327 const int VF_conservatif = 4;
00328 const int VF_non_conservatif = 5;
00329
00330 const int connexite = 0;
00331 const int conn_octree = 1;
00332 const int brutal = 2;
00333
00334 const int support_noeud = 0;
00335 const int support_maille = 1;
00336
00337
00338
00339
00340
00341 const int MAX_NB_GROUP = 100000;
00342
00343
00344
00345
00346
00347 typedef enum {V21 = 26, V22 = 75} medFileVersion;
00348
00349
00350 }
00351
00352
00353 #endif