--- /dev/null
+dnl Copyright (C) 2004-2012 CEA/DEN, EDF R&D
+dnl
+dnl This library is free software; you can redistribute it and/or
+dnl modify it under the terms of the GNU Lesser General Public
+dnl License as published by the Free Software Foundation; either
+dnl version 2.1 of the License.
+dnl
+dnl This library is distributed in the hope that it will be useful,
+dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
+dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+dnl Lesser General Public License for more details.
+dnl
+dnl You should have received a copy of the GNU Lesser General Public
+dnl License along with this library; if not, write to the Free Software
+dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+dnl
+dnl See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+dnl
+
+AC_DEFUN([CHECK_MESHGEMS_TETRA],[
+
+AC_CHECKING([for MeshGems-Tetra commercial product])
+
+MeshGems_Tetra_ok=no
+
+AC_EXEEXT
+AC_CHECK_PROG(MESHGEMS_TETRA, mg-tetra.exe$EXEEXT,found)
+
+if test "x$MESHGEMS_TETRA" == x ; then
+ AC_MSG_WARN(mg-tetra program not found in PATH variable)
+else
+ MeshGems_Tetra_ok=yes
+fi
+
+AC_MSG_RESULT(for MeshGems-Tetra: $MeshGems_Tetra_ok)
+
+])dnl
echo
echo ---------------------------------------------
-echo Testing GHS3D
+echo Testing MeshGems-Tetra
echo ---------------------------------------------
echo
-CHECK_GHS3D
-if test "${GHS3D_ok}" = "yes"; then
- if test "x$GHS3D_VERSION" = "x"
- then
- GHS3D_VERSION=`ghs3d -u |grep "TETMESH-GHS3D SOFTWARE"|awk '{print $3}'|awk -F- '{print $1}'|awk -F. '{print $1$2}'`
- fi
- AC_DEFINE_UNQUOTED(GHS3D_VERSION,${GHS3D_VERSION})
-fi
+CHECK_MESHGEMS_TETRA
echo
echo ---------------------------------------------
echo Configure
if test "${gui_ok}" = "yes"; then
- variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok gui_ok Geom_ok Med_ok SMesh_ok GHS3D_ok OpenGL_ok qt_ok vtk_ok"
+ variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok gui_ok Geom_ok Med_ok SMesh_ok MeshGems_Tetra_ok OpenGL_ok qt_ok vtk_ok"
elif test "${SalomeGUI_need}" != "no"; then
- variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok gui_ok Geom_ok Med_ok SMesh_ok GHS3D_ok vtk_ok"
+ variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok gui_ok Geom_ok Med_ok SMesh_ok MeshGems_Tetra_ok vtk_ok"
else
- variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok Geom_ok Med_ok SMesh_ok GHS3D_ok vtk_ok"
+ variables="cc_ok boost_ok threads_ok omniORB_ok occ_ok doxygen_ok Kernel_ok Geom_ok Med_ok SMesh_ok MeshGems_Tetra_ok vtk_ok"
fi
for var in $variables
GHS3DEnforcedMeshList GetEnforcedMeshes();
void ClearEnforcedMeshes();
+
/*!
* Set/get/unset an enforced vertex (private method for GUI)
*/
#define HOLE_ID -1
-#ifndef GHS3D_VERSION
-#define GHS3D_VERSION 41
-#endif
-
typedef const list<const SMDS_MeshFace*> TTriaList;
static void removeFile( const TCollection_AsciiString& fileName )
return meshDS->ShapeToIndex( solids(2) );
}
-//=======================================================================
-//function : countShape
-//purpose :
-//=======================================================================
-
+// //=======================================================================
+// //function : countShape
+// //purpose :
+// //=======================================================================
+//
// template < class Mesh, class Shape >
// static int countShape( Mesh* mesh, Shape shape ) {
// TopExp_Explorer expShape ( mesh->ShapeToMesh(), shape );
// }
// return nbShape;
// }
-
-//=======================================================================
-//function : getShape
-//purpose :
-//=======================================================================
-
+//
+// //=======================================================================
+// //function : getShape
+// //purpose :
+// //=======================================================================
+//
// template < class Mesh, class Shape, class Tab >
// void getShape(Mesh* mesh, Shape shape, Tab *t_Shape) {
// TopExp_Explorer expShape ( mesh->ShapeToMesh(), shape );
// }
// return;
// }
-
-// //=======================================================================
-// //function : findEdgeID
-// //purpose :
-// //=======================================================================
+//
+// // //=======================================================================
+// // //function : findEdgeID
+// // //purpose :
+// // //=======================================================================
//
// static int findEdgeID(const SMDS_MeshNode* aNode,
// const SMESHDS_Mesh* theMesh,
// delete [] t_Dist;
// return theMesh->ShapeToIndex( foundEdge );
// }
-
-
-//=======================================================================
-//function : readGMFFile
-//purpose : read GMF file with geometry associated to mesh
-// TODO
-//=======================================================================
-
-// static bool readGMFFile(
-// const int fileOpen,
+//
+//
+// // =======================================================================
+// // function : readGMFFile
+// // purpose : read GMF file with geometry associated to mesh
+// // =======================================================================
+//
+// static bool readGMFFile(const int fileOpen,
// const char* theFileName,
// SMESH_Mesh& theMesh,
// const int nbShape,
//
//
// // The keyword does not exist yet => to update when it is created
-// // int nbTriangle = GmfStatKwd(InpMsh, GmfSubdomain);
+// // int nbSubdomains = GmfStatKwd(InpMsh, GmfSubdomain);
// // int id_tri[3];
//
//
// // case GmfHexahedra:
// {
// int nodeDim, shapeID, *nodeID;
-// SMDS_MeshNode** node;
+// const SMDS_MeshNode** node;
// // std::vector< SMDS_MeshNode* > enfNode( nbRef );
// SMDS_MeshElement * aGMFElement;
//
-// node = new SMDS_MeshNode*[nbRef];
+// node = new const SMDS_MeshNode*[nbRef];
// nodeID = new int[ nbRef ];
//
// for ( int iElem = 0; iElem < nbElem; iElem++ )
const bool hasShapeToMesh)
{
TCollection_AsciiString cmd;
- if (hasShapeToMesh)
- cmd = "ghs3d-41"; // to use old mesh2 format
- else
- cmd = "ghs3d"; // to use new mesh format
+ cmd = "mg-tetra.exe";
// check if any option is overridden by hyp->myTextOption
bool m = hyp ? ( hyp->myTextOption.find("-m") == std::string::npos ) : true;
bool M = hyp ? ( hyp->myTextOption.find("-M") == std::string::npos ) : true;
// #include <SALOMEconfig.h>
// #include CORBA_SERVER_HEADER(SALOMEDS)
-#ifndef GHS3D_VERSION
-#define GHS3D_VERSION 41
-#endif
//=======================================================================
//function : GHS3DPlugin_Hypothesis_i
//=======================================================================
bool GHS3DPlugin_Hypothesis_i::SetEnforcedMeshWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, const char* theGroupName)
throw (SALOME::SALOME_Exception)
{
-#if GHS3D_VERSION >= 42
+// #if GHS3D_VERSION >= 42
return p_SetEnforcedMesh(theSource, theType, "", theGroupName);
-#else
- SALOME::ExceptionStruct ExDescription;
- ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
- ExDescription.type = SALOME::BAD_PARAM;
- ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
- ExDescription.lineNumber = 719;
- throw SALOME::SALOME_Exception(ExDescription);
-#endif
+// #else
+// SALOME::ExceptionStruct ExDescription;
+// ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
+// ExDescription.type = SALOME::BAD_PARAM;
+// ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
+// ExDescription.lineNumber = 719;
+// throw SALOME::SALOME_Exception(ExDescription);
+// #endif
}
/*!
throw (SALOME::SALOME_Exception)
{
// MESSAGE("GHS3DPlugin_Hypothesis_i::SetEnforcedMesh");
-#if GHS3D_VERSION >= 42
+// #if GHS3D_VERSION >= 42
return p_SetEnforcedMesh(theSource, theType);
-#else
- SALOME::ExceptionStruct ExDescription;
- ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
- ExDescription.type = SALOME::BAD_PARAM;
- ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
- ExDescription.lineNumber = 750;
- throw SALOME::SALOME_Exception(ExDescription);
-#endif
+// #else
+// SALOME::ExceptionStruct ExDescription;
+// ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
+// ExDescription.type = SALOME::BAD_PARAM;
+// ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
+// ExDescription.lineNumber = 750;
+// throw SALOME::SALOME_Exception(ExDescription);
+// #endif
}
/*!
bool GHS3DPlugin_Hypothesis_i::SetEnforcedMeshSizeWithGroup(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double theSize, const char* theGroupName)
throw (SALOME::SALOME_Exception)
{
-#if GHS3D_VERSION >= 42
+// #if GHS3D_VERSION >= 42
return p_SetEnforcedMesh(theSource, theType, "", theGroupName);
-#else
- SALOME::ExceptionStruct ExDescription;
- ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
- ExDescription.type = SALOME::BAD_PARAM;
- ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
- ExDescription.lineNumber = 750;
- throw SALOME::SALOME_Exception(ExDescription);
-#endif
+// #else
+// SALOME::ExceptionStruct ExDescription;
+// ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
+// ExDescription.type = SALOME::BAD_PARAM;
+// ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
+// ExDescription.lineNumber = 750;
+// throw SALOME::SALOME_Exception(ExDescription);
+// #endif
}
/*!
bool GHS3DPlugin_Hypothesis_i::SetEnforcedMeshSize(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, double theSize)
throw (SALOME::SALOME_Exception)
{
-#if GHS3D_VERSION >= 42
+// #if GHS3D_VERSION >= 42
return p_SetEnforcedMesh(theSource, theType);
-#else
- SALOME::ExceptionStruct ExDescription;
- ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
- ExDescription.type = SALOME::BAD_PARAM;
- ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
- ExDescription.lineNumber = 750;
- throw SALOME::SALOME_Exception(ExDescription);
-#endif
+// #else
+// SALOME::ExceptionStruct ExDescription;
+// ExDescription.text = "Bad version of GHS3D. It must >= 4.2.";
+// ExDescription.type = SALOME::BAD_PARAM;
+// ExDescription.sourceFile = "GHS3DPlugin_Hypothesis_i.cxx";
+// ExDescription.lineNumber = 750;
+// throw SALOME::SALOME_Exception(ExDescription);
+// #endif
}
bool GHS3DPlugin_Hypothesis_i::p_SetEnforcedMesh(SMESH::SMESH_IDSource_ptr theSource, SMESH::ElementType theType, const char* theName, const char* theGroupName)
GHS3DPlugin_Hypothesis_i.cxx
libGHS3DEngine_la_CPPFLAGS = \
- $(KERNEL_CXXFLAGS) \
- $(CAS_CPPFLAGS) \
- $(GEOM_CXXFLAGS) \
- $(MED_CXXFLAGS) \
- $(SMESH_CXXFLAGS) \
- $(VTK_INCLUDES) \
- $(BOOST_CPPFLAGS) \
- $(CORBA_CXXFLAGS) \
- $(CORBA_INCLUDES) \
- -I$(top_builddir)/idl
+ $(KERNEL_CXXFLAGS) \
+ $(CAS_CPPFLAGS) \
+ $(GEOM_CXXFLAGS) \
+ $(MED_CXXFLAGS) \
+ $(SMESH_CXXFLAGS) \
+ $(VTK_INCLUDES) \
+ $(BOOST_CPPFLAGS) \
+ $(CORBA_CXXFLAGS) \
+ $(CORBA_INCLUDES) \
+ -I$(top_builddir)/idl
libGHS3DEngine_la_LDFLAGS = \
../../idl/libSalomeIDLGHS3DPLUGIN.la \