28 #ifndef SMESH_MeshEditor_HeaderFile 29 #define SMESH_MeshEditor_HeaderFile 31 #include "Standard_Version.hxx" 41 #include <TColStd_HSequenceOfReal.hxx> 58 typedef std::map<const SMDS_MeshNode*, const SMDS_MeshNode*>
TNodeNodeMap;
63 typedef pair< const SMDS_MeshNode*, const SMDS_MeshNode* >
NLink;
89 std::vector< const SMDS_MeshElement* >& foundElems)=0;
101 {
if ( n1->
GetID() < n2->
GetID() ) std::swap( first, second ); }
103 {
if ( first->GetID() < second->GetID() ) std::swap( first, second ); }
116 myPnt.SetCoord(99., 99., 99.);
117 myTgt.SetCoord(1.,0.,0.);
169 SMDS_MeshElement* AddElement(
const std::vector<const SMDS_MeshNode*> & nodes,
181 bool Remove (
const std::list< int >& theElemIDs,
const bool isNodes);
217 const double theMaxAngle);
235 const bool the13Diag);
250 std::set<const SMDS_MeshNode*> & theFixedNodes,
251 const SmoothMethod theSmoothMethod,
252 const int theNbIterations,
253 double theTgtAspectRatio = 1.0,
254 const bool the2D =
true);
267 const gp_Ax1& theAxis,
268 const double theAngle,
269 const int theNbSteps,
270 const double theToler,
271 const bool theMakeGroups,
272 const bool theMakeWalls=
true);
282 EXTRUSION_FLAG_BOUNDARY = 0x01,
283 EXTRUSION_FLAG_SEW = 0x02
291 Handle(TColStd_HSequenceOfReal) mySteps;
302 const double tolnode,
318 const gp_Vec& theStep,
319 const int theNbSteps,
321 const bool theMakeGroups,
322 const int theFlags = EXTRUSION_FLAG_BOUNDARY,
323 const double theTolerance = 1.e-6);
338 const bool theMakeGroups,
340 const double theTolerance);
353 EXTR_CANT_GET_TANGENT
359 const bool theHasAngles,
360 std::list<double>& theAngles,
361 const bool theLinearVariation,
362 const bool theHasRefPoint,
363 const gp_Pnt& theRefPoint,
364 const bool theMakeGroups);
368 const bool theHasAngles,
369 std::list<double>& theAngles,
370 const bool theLinearVariation,
371 const bool theHasRefPoint,
372 const gp_Pnt& theRefPoint,
373 const bool theMakeGroups);
378 const gp_Trsf& theTrsf,
380 const bool theMakeGroups,
387 void FindCoincidentNodes (std::set<const SMDS_MeshNode*> & theNodes,
388 const double theTolerance,
405 static bool isOut(
const SMDS_MeshElement* element,
const gp_Pnt& point,
double tol );
408 int SimplifyFace (
const std::vector<const SMDS_MeshNode *> faceNodes,
409 std::vector<const SMDS_MeshNode *>& poly_nodes,
410 std::vector<int>& quantities)
const;
420 void FindEqualElements(std::set<const SMDS_MeshElement*> & theElements,
428 void MergeEqualElements();
432 static bool CheckFreeBorderNodes(
const SMDS_MeshNode* theNode1,
437 static bool FindFreeBorder (
const SMDS_MeshNode* theFirstNode,
440 std::list< const SMDS_MeshNode* > & theNodes,
441 std::list< const SMDS_MeshElement* >& theFaces);
461 Sew_Error SewFreeBorder (
const SMDS_MeshNode* theBorderFirstNode,
467 const bool theSide2IsFreeBorder =
true,
468 const bool toCreatePolygons =
false,
469 const bool toCreatePolyedrs =
false);
506 std::list<const SMDS_MeshNode*>& theNodesToInsert,
507 const bool toCreatePoly =
false);
513 std::list<const SMDS_MeshNode*>& theNodesToInsert);
517 void ConvertToQuadratic(
const bool theForce3d);
521 bool ConvertFromQuadratic();
578 static Sew_Error FindMatchingNodes(std::set<const SMDS_MeshElement*>& theSide1,
579 std::set<const SMDS_MeshElement*>& theSide2,
607 bool DoubleNodes(
const std::list< int >& theListOfNodes,
608 const std::list< int >& theListOfModifiedElems );
616 const TopoDS_Shape& theShape );
623 bool Make2DMeshFrom3D();
633 const bool theForce3d);
641 const int theShapeID);
650 const std::string& postfix,
668 const std::vector<TNodeOfNodeListMapItr> & newNodesItVec,
669 std::list<const SMDS_MeshElement*>& newElems,
693 const TopoDS_Edge& aTrackEdge,
695 list<SMESH_MeshEditor_PathPoint>& LPP);
697 list<SMESH_MeshEditor_PathPoint>& fullList,
698 const bool theHasAngles,
699 list<double>& theAngles,
700 const bool theLinearVariation,
701 const bool theHasRefPoint,
702 const gp_Pnt& theRefPoint,
703 const bool theMakeGroups);
704 void LinearAngleVariation(
const int NbSteps,
705 list<double>& theAngles);
712 const bool theIsDoubleElem );
class Handle(MeshVS_DataSource3D)
SMESH_MeshEditor_PathPoint()
const SMESH_SequenceOfElemPtr & GetLastCreatedElems() const
void SetTangent(const gp_Dir &aTgt)
std::vector< TNodeOfNodeListMapItr > TVecOfNnlmiMap
Return elements of given type where the given point is IN or ON.
boost::shared_ptr< NumericalFunctor > NumericalFunctorPtr
SMESH_SequenceOfNode myNodes
const gp_Pnt & Pnt() const
SMESH_TLink(const SMDS_MeshNode *n1, const SMDS_MeshNode *n2)
std::map< const SMDS_MeshNode *, std::list< const SMDS_MeshNode * > > TNodeOfNodeListMap
boost::shared_ptr< SMDS_Iterator< const SMDS_MeshElement * > > SMDS_ElemIteratorPtr
const SMESH_SequenceOfElemPtr & GetLastCreatedNodes() const
virtual const SMDS_MeshNode * FindClosestTo(const gp_Pnt &pnt)=0
SMESH_SequenceOfElemPtr myLastCreatedNodes
void SetParameter(const double &aPrm)
SMESH_SequenceOfElemPtr myLastCreatedElems
SMDSAbs_ElementType
Type (node, edge, face or volume) of elements.
const SMDS_MeshNode * node1() const
NCollection_Sequence< SMDS_MeshElementPtr > SMESH_SequenceOfElemPtr
void SetAngle(const double &aBeta)
pair< const SMDS_MeshNode *, const SMDS_MeshNode *> NLink
std::auto_ptr< std::list< int > > PGroupIDs
const gp_Dir & Tangent() const
void SetPnt(const gp_Pnt &aP3D)
const SMDS_MeshNode * node2() const
std::set< const SMDS_MeshElement *, TIDCompare > TIDSortedElemSet
std::list< std::list< int > > TListOfListOfElementsID
std::map< const SMDS_MeshNode *, const SMDS_MeshNode * > TNodeNodeMap
Set of elements sorted by ID, to be used to assure predictability of edition.
virtual void FindElementsByPoint(const gp_Pnt &point, SMDSAbs_ElementType type, std::vector< const SMDS_MeshElement * > &foundElems)=0
NCollection_Sequence< SMDS_MeshNodePtr > SMESH_SequenceOfNode
Searcher for the node closest to point.
std::map< const SMDS_MeshElement *, TVecOfNnlmiMap > TElemOfVecOfNnlmiMap
virtual void MoveNode(const SMDS_MeshNode *node, const gp_Pnt &toPnt)=0
SMESH_TLink(const NLink &link)
std::list< std::list< const SMDS_MeshNode *> > TListOfListOfNodes
TNodeOfNodeListMap::iterator TNodeOfNodeListMapItr
std::map< const SMDS_MeshElement *, std::list< const SMDS_MeshElement * > > TElemOfElemListMap
SMESHDS_Mesh * GetMeshDS()