interface NumericalFunctor;
interface SMESH_MeshEditor
{
+ /*!
+ * \brief Wrap a sequence of ids in a SMESH_IDSource
+ */
+ SMESH_IDSource MakeIDSource(in long_array IDsOfElements);
+
boolean RemoveElements(in long_array IDsOfElements);
boolean RemoveNodes(in long_array IDsOfNodes);
long BestSplit (in long IDOfQuad,
in NumericalFunctor Criterion);
+ /*!
+ * \brief Split volumic elements into tetrahedrons
+ * \param elems - elements to split
+ * \param methodFlags - flags passing splitting method:
+ * 1 - split the hexahedron into 5 tetrahedrons
+ * 2 - split the hexahedron into 6 tetrahedrons
+ */
+ //void SplitVolumesIntoTetra(in SMESH_IDSource elems, in short methodFlags)
+ //raises (SALOME::SALOME_Exception);
+
+
enum Smooth_Method { LAPLACIAN_SMOOTH, CENTROIDAL_SMOOTH };
boolean Smooth(in long_array IDsOfElements,
}
}
+//=======================================================================
+//function : MakeIDSource
+//purpose : Wrap a sequence of ids in a SMESH_IDSource
+//=======================================================================
+
+struct _IDSource : public POA_SMESH::SMESH_IDSource
+{
+ SMESH::long_array _ids;
+ SMESH::long_array* GetIDs() { return & _ids; }
+ SMESH::long_array* GetMeshInfo() { return 0; }
+};
+
+SMESH::SMESH_IDSource_ptr SMESH_MeshEditor_i::MakeIDSource(const SMESH::long_array& ids)
+{
+ _IDSource* anIDSource = new _IDSource;
+ anIDSource->_ids = ids;
+ SMESH::SMESH_IDSource_var anIDSourceVar = anIDSource->_this();
+
+ return anIDSourceVar._retn();
+}
+
//=============================================================================
/*!
*
class SMESH_MeshEditor_i: public POA_SMESH::SMESH_MeshEditor
{
- public:
+public:
SMESH_MeshEditor_i(SMESH_Mesh_i * theMesh, bool isPreview);
virtual ~ SMESH_MeshEditor_i();
// --- CORBA
+
+ /*!
+ * \brief Wrap a sequence of ids in a SMESH_IDSource
+ */
+ SMESH::SMESH_IDSource_ptr MakeIDSource(const SMESH::long_array& IDsOfElements);
+
CORBA::Boolean RemoveElements(const SMESH::long_array & IDsOfElements);
CORBA::Boolean RemoveNodes(const SMESH::long_array & IDsOfNodes);