1 // Copyright (C) 2004-2016 CEA/DEN, EDF R&D
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
8 // This library 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. See the GNU
11 // Lesser General Public License for more details.
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 #ifndef __MG_Tetra_IO_HXX__
21 #define __MG_Tetra_IO_HXX__
31 * \brief Class providing a transparent switch between MG_Tetra usage as
32 * a library and as an executable. API of libmesh5 inherited.
38 MG_Tetra_API( volatile bool& cancelled_flag, double& progress );
42 bool IsExecutable() { return !IsLibrary(); }
43 void SetUseExecutable();
46 int GmfOpenMesh(const char* theFile, int rdOrWr, int ver, int dim);
47 void GmfSetKwd(int iMesh, GmfKwdCod what, int nb );
48 void GmfSetLin(int iMesh, GmfKwdCod what, double x, double y, double z, int domain);
49 void GmfSetKwd(int iMesh, GmfKwdCod what, int nbNodes, int dummy, int type[] ); // sol type
50 void GmfSetLin(int iMesh, GmfKwdCod what, double vals[]); // sol
51 void GmfSetLin(int iMesh, GmfKwdCod what, int node1, int node2, int domain ); // edge
52 void GmfSetLin(int iMesh, GmfKwdCod what, int id ); // required
53 void GmfSetLin(int iMesh, GmfKwdCod what, int node1, int node2, int node3, int domain ); // tria
54 void GmfSetLin(int iMesh, GmfKwdCod what, int node1, int node2, int node3, int node4, int domain ); // tetra
56 bool Compute( const std::string& cmdLine, std::string& errStr );
59 int GmfOpenMesh(const char* theFile, int rdOrWr, int * ver, int * dim);
60 int GmfStatKwd( int iMesh, GmfKwdCod what );
61 void GmfGotoKwd( int iMesh, GmfKwdCod what );
62 void GmfGetLin( int iMesh, GmfKwdCod what, int* nbNodes, int* faceInd, int* ori, int* domain, int dummy );
63 void GmfGetLin(int iMesh, GmfKwdCod what, float* x, float* y, float *z, int* domain );
64 void GmfGetLin(int iMesh, GmfKwdCod what, double* x, double* y, double *z, int* domain );
65 void GmfGetLin(int iMesh, GmfKwdCod what, int* node );
66 void GmfGetLin(int iMesh, GmfKwdCod what, int* node1, int* node2, int* domain );
67 void GmfGetLin(int iMesh, GmfKwdCod what, int* node1, int* node2, int* node3, int* domain );
68 void GmfGetLin(int iMesh, GmfKwdCod what, int* node1, int* node2, int* node3, int* node4, int* domain );
69 void GmfGetLin(int iMesh, GmfKwdCod what, int* node1, int* node2, int* node3, int* node4, int* node5, int* node6, int* node7, int* node8, int* domain );
70 void GmfCloseMesh( int iMesh );
72 void SetLogFile( const std::string& logFileName ) { _logFile = logFileName; }
83 std::set<int> _openFiles;