SALOME - SMESH
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
SMESH_MeshEditor Class Reference

Editor of a mesh. More...

#include <SMESH_MeshEditor.hxx>

Collaboration diagram for SMESH_MeshEditor:
Collaboration graph

Data Structures

struct  ExtrusParam
 

Public Types

enum  SmoothMethod { LAPLACIAN = 0, CENTROIDAL }
 
enum  ExtrusionFlags { EXTRUSION_FLAG_BOUNDARY = 0x01, EXTRUSION_FLAG_SEW = 0x02 }
 
enum  Extrusion_Error {
  EXTR_OK, EXTR_NO_ELEMENTS, EXTR_PATH_NOT_EDGE, EXTR_BAD_PATH_SHAPE,
  EXTR_BAD_STARTING_NODE, EXTR_BAD_ANGLES_NUMBER, EXTR_CANT_GET_TANGENT
}
 
enum  Sew_Error {
  SEW_OK, SEW_BORDER1_NOT_FOUND, SEW_BORDER2_NOT_FOUND, SEW_BOTH_BORDERS_NOT_FOUND,
  SEW_BAD_SIDE_NODES, SEW_VOLUMES_TO_SPLIT, SEW_DIFF_NB_OF_ELEMENTS, SEW_TOPO_DIFF_SETS_OF_ELEMENTS,
  SEW_BAD_SIDE1_NODES, SEW_BAD_SIDE2_NODES, SEW_INTERNAL_ERROR
}
 
typedef std::auto_ptr
< std::list< int > > 
PGroupIDs
 
typedef std::list< std::list
< const SMDS_MeshNode * > > 
TListOfListOfNodes
 
typedef std::list< std::list
< int > > 
TListOfListOfElementsID
 

Public Member Functions

 SMESH_MeshEditor (SMESH_Mesh *theMesh)
 
SMDS_MeshElementAddElement (const std::vector< const SMDS_MeshNode * > &nodes, const SMDSAbs_ElementType type, const bool isPoly, const int ID=0)
 Add element. More...
 
SMDS_MeshElementAddElement (const std::vector< int > &nodeIDs, const SMDSAbs_ElementType type, const bool isPoly, const int ID=0)
 Add element. More...
 
bool Remove (const std::list< int > &theElemIDs, const bool isNodes)
 
bool InverseDiag (const SMDS_MeshElement *theTria1, const SMDS_MeshElement *theTria2)
 
bool InverseDiag (const SMDS_MeshNode *theNode1, const SMDS_MeshNode *theNode2)
 
bool DeleteDiag (const SMDS_MeshNode *theNode1, const SMDS_MeshNode *theNode2)
 
bool Reorient (const SMDS_MeshElement *theElement)
 
bool TriToQuad (TIDSortedElemSet &theElems, SMESH::Controls::NumericalFunctorPtr theCriterion, const double theMaxAngle)
 Fuse neighbour triangles into quadrangles. More...
 
bool QuadToTri (TIDSortedElemSet &theElems, SMESH::Controls::NumericalFunctorPtr theCriterion)
 Split quadrangles into triangles. More...
 
bool QuadToTri (TIDSortedElemSet &theElems, const bool the13Diag)
 Split quadrangles into triangles. More...
 
int BestSplit (const SMDS_MeshElement *theQuad, SMESH::Controls::NumericalFunctorPtr theCriterion)
 Find better diagonal for splitting. More...
 
void Smooth (TIDSortedElemSet &theElements, std::set< const SMDS_MeshNode * > &theFixedNodes, const SmoothMethod theSmoothMethod, const int theNbIterations, double theTgtAspectRatio=1.0, const bool the2D=true)
 
PGroupIDs RotationSweep (TIDSortedElemSet &theElements, const gp_Ax1 &theAxis, const double theAngle, const int theNbSteps, const double theToler, const bool theMakeGroups, const bool theMakeWalls=true)
 
const SMDS_MeshNodeCreateNode (const double x, const double y, const double z, const double tolnode, SMESH_SequenceOfNode &aNodes)
 
PGroupIDs ExtrusionSweep (TIDSortedElemSet &theElems, const gp_Vec &theStep, const int theNbSteps, TElemOfElemListMap &newElemsMap, const bool theMakeGroups, const int theFlags=EXTRUSION_FLAG_BOUNDARY, const double theTolerance=1.e-6)
 
PGroupIDs ExtrusionSweep (TIDSortedElemSet &theElems, ExtrusParam &theParams, TElemOfElemListMap &newElemsMap, const bool theMakeGroups, const int theFlags, const double theTolerance)
 
Extrusion_Error ExtrusionAlongTrack (TIDSortedElemSet &theElements, SMESH_subMesh *theTrackPattern, const SMDS_MeshNode *theNodeStart, const bool theHasAngles, std::list< double > &theAngles, const bool theHasRefPoint, const gp_Pnt &theRefPoint, const bool theMakeGroups)
 
PGroupIDs Transform (TIDSortedElemSet &theElements, const gp_Trsf &theTrsf, const bool theCopy, const bool theMakeGroups, SMESH_Mesh *theTargetMesh=0)
 
void FindCoincidentNodes (std::set< const SMDS_MeshNode * > &theNodes, const double theTolerance, TListOfListOfNodes &theGroupsOfNodes)
 
SMESH_NodeSearcherGetNodeSearcher ()
 Return SMESH_NodeSearcher. More...
 
int SimplifyFace (const std::vector< const SMDS_MeshNode * > faceNodes, std::vector< const SMDS_MeshNode * > &poly_nodes, std::vector< int > &quantities) const
 
void MergeNodes (TListOfListOfNodes &theNodeGroups)
 
void FindEqualElements (std::set< const SMDS_MeshElement * > &theElements, TListOfListOfElementsID &theGroupsOfElementsID)
 
void MergeElements (TListOfListOfElementsID &theGroupsOfElementsID)
 
void MergeEqualElements ()
 
Sew_Error SewFreeBorder (const SMDS_MeshNode *theBorderFirstNode, const SMDS_MeshNode *theBorderSecondNode, const SMDS_MeshNode *theBorderLastNode, const SMDS_MeshNode *theSide2FirstNode, const SMDS_MeshNode *theSide2SecondNode, const SMDS_MeshNode *theSide2ThirdNode=0, const bool theSide2IsFreeBorder=true, const bool toCreatePolygons=false, const bool toCreatePolyedrs=false)
 
Sew_Error SewSideElements (TIDSortedElemSet &theSide1, TIDSortedElemSet &theSide2, const SMDS_MeshNode *theFirstNode1ToMerge, const SMDS_MeshNode *theFirstNode2ToMerge, const SMDS_MeshNode *theSecondNode1ToMerge, const SMDS_MeshNode *theSecondNode2ToMerge)
 
void InsertNodesIntoLink (const SMDS_MeshElement *theFace, const SMDS_MeshNode *theBetweenNode1, const SMDS_MeshNode *theBetweenNode2, std::list< const SMDS_MeshNode * > &theNodesToInsert, const bool toCreatePoly=false)
 
void UpdateVolumes (const SMDS_MeshNode *theBetweenNode1, const SMDS_MeshNode *theBetweenNode2, std::list< const SMDS_MeshNode * > &theNodesToInsert)
 
void ConvertToQuadratic (const bool theForce3d)
 
bool ConvertFromQuadratic ()
 
int FindShape (const SMDS_MeshElement *theElem)
 
SMESH_MeshGetMesh ()
 
SMESHDS_MeshGetMeshDS ()
 
const SMESH_SequenceOfElemPtr & GetLastCreatedNodes () const
 
const SMESH_SequenceOfElemPtr & GetLastCreatedElems () const
 
bool DoubleNodes (const std::list< int > &theListOfNodes, const std::list< int > &theListOfModifiedElems)
 

Static Public Member Functions

static bool CheckFreeBorderNodes (const SMDS_MeshNode *theNode1, const SMDS_MeshNode *theNode2, const SMDS_MeshNode *theNode3=0)
 
static bool FindFreeBorder (const SMDS_MeshNode *theFirstNode, const SMDS_MeshNode *theSecondNode, const SMDS_MeshNode *theLastNode, std::list< const SMDS_MeshNode * > &theNodes, std::list< const SMDS_MeshElement * > &theFaces)
 
static void AddToSameGroups (const SMDS_MeshElement *elemToAdd, const SMDS_MeshElement *elemInGroups, SMESHDS_Mesh *aMesh)
 
static void RemoveElemFromGroups (const SMDS_MeshElement *element, SMESHDS_Mesh *aMesh)
 
static void ReplaceElemInGroups (const SMDS_MeshElement *elemToRm, const SMDS_MeshElement *elemToAdd, SMESHDS_Mesh *aMesh)
 
static void GetLinkedNodes (const SMDS_MeshNode *node, TIDSortedElemSet &linkedNodes, SMDSAbs_ElementType type=SMDSAbs_All)
 Return nodes linked to the given one in elements of the type. More...
 
static const SMDS_MeshElementFindFaceInSet (const SMDS_MeshNode *n1, const SMDS_MeshNode *n2, const TIDSortedElemSet &elemSet, const TIDSortedElemSet &avoidSet)
 
static Sew_Error FindMatchingNodes (std::set< const SMDS_MeshElement * > &theSide1, std::set< const SMDS_MeshElement * > &theSide2, const SMDS_MeshNode *theFirstNode1, const SMDS_MeshNode *theFirstNode2, const SMDS_MeshNode *theSecondNode1, const SMDS_MeshNode *theSecondNode2, TNodeNodeMap &nReplaceMap)
 Find corresponding nodes in two sets of faces. More...
 
static bool IsMedium (const SMDS_MeshNode *node, const SMDSAbs_ElementType typeToCheck=SMDSAbs_All)
 Returns true if given node is medium. More...
 

Private Types

typedef std::map< const
SMDS_MeshNode *, std::list
< const SMDS_MeshNode * > > 
TNodeOfNodeListMap
 
typedef
TNodeOfNodeListMap::iterator 
TNodeOfNodeListMapItr
 
typedef std::vector
< TNodeOfNodeListMapItr
TVecOfNnlmiMap
 
typedef std::map< const
SMDS_MeshElement
*, TVecOfNnlmiMap
TElemOfVecOfNnlmiMap
 

Private Member Functions

int convertElemToQuadratic (SMESHDS_SubMesh *theSm, SMESH_MesherHelper &theHelper, const bool theForce3d)
 Convert elements contained in a submesh to quadratic. More...
 
int removeQuadElem (SMESHDS_SubMesh *theSm, SMDS_ElemIteratorPtr theItr, const int theShapeID)
 Convert quadratic elements to linear ones and remove quadratic nodes. More...
 
PGroupIDs generateGroups (const SMESH_SequenceOfElemPtr &nodeGens, const SMESH_SequenceOfElemPtr &elemGens, const std::string &postfix, SMESH_Mesh *targetMesh=0)
 Create groups of elements made during transformation. More...
 
void sweepElement (const SMDS_MeshElement *elem, const std::vector< TNodeOfNodeListMapItr > &newNodesItVec, std::list< const SMDS_MeshElement * > &newElems, const int nbSteps, SMESH_SequenceOfElemPtr &srcElements)
 Create elements by sweeping an element. More...
 
void makeWalls (TNodeOfNodeListMap &mapNewNodes, TElemOfElemListMap &newElemsMap, TElemOfVecOfNnlmiMap &elemNewNodesMap, TIDSortedElemSet &elemSet, const int nbSteps, SMESH_SequenceOfElemPtr &srcElements)
 Create 1D and 2D elements around swept elements. More...
 

Private Attributes

SMESH_MeshmyMesh
 
SMESH_SequenceOfElemPtr myLastCreatedNodes
 
SMESH_SequenceOfElemPtr myLastCreatedElems
 

Detailed Description

Editor of a mesh.

Definition at line 94 of file SMESH_MeshEditor.hxx.

Member Typedef Documentation

typedef std::auto_ptr< std::list<int> > SMESH_MeshEditor::PGroupIDs

Definition at line 198 of file SMESH_MeshEditor.hxx.

typedef std::list< std::list< const SMDS_MeshNode* > > SMESH_MeshEditor::TListOfListOfNodes

Definition at line 308 of file SMESH_MeshEditor.hxx.

typedef std::list< std::list< int > > SMESH_MeshEditor::TListOfListOfElementsID

Definition at line 331 of file SMESH_MeshEditor.hxx.

typedef std::map<const SMDS_MeshNode*, std::list<const SMDS_MeshNode*> > SMESH_MeshEditor::TNodeOfNodeListMap
private

Definition at line 552 of file SMESH_MeshEditor.hxx.

typedef TNodeOfNodeListMap::iterator SMESH_MeshEditor::TNodeOfNodeListMapItr
private

Definition at line 553 of file SMESH_MeshEditor.hxx.

Definition at line 554 of file SMESH_MeshEditor.hxx.

Definition at line 555 of file SMESH_MeshEditor.hxx.

Member Enumeration Documentation

Enumerator
LAPLACIAN 
CENTROIDAL 

Definition at line 181 of file SMESH_MeshEditor.hxx.

Auxilary flag for advanced extrusion. BOUNDARY: create or not boundary for result of extrusion SEW: try to use existing nodes or create new nodes in any case

Enumerator
EXTRUSION_FLAG_BOUNDARY 
EXTRUSION_FLAG_SEW 

Definition at line 215 of file SMESH_MeshEditor.hxx.

Enumerator
EXTR_OK 
EXTR_NO_ELEMENTS 
EXTR_PATH_NOT_EDGE 
EXTR_BAD_PATH_SHAPE 
EXTR_BAD_STARTING_NODE 
EXTR_BAD_ANGLES_NUMBER 
EXTR_CANT_GET_TANGENT 

Definition at line 280 of file SMESH_MeshEditor.hxx.

Enumerator
SEW_OK 
SEW_BORDER1_NOT_FOUND 
SEW_BORDER2_NOT_FOUND 
SEW_BOTH_BORDERS_NOT_FOUND 
SEW_BAD_SIDE_NODES 
SEW_VOLUMES_TO_SPLIT 
SEW_DIFF_NB_OF_ELEMENTS 
SEW_TOPO_DIFF_SETS_OF_ELEMENTS 
SEW_BAD_SIDE1_NODES 
SEW_BAD_SIDE2_NODES 
SEW_INTERNAL_ERROR 

Definition at line 357 of file SMESH_MeshEditor.hxx.

Constructor & Destructor Documentation

SMESH_MeshEditor::SMESH_MeshEditor ( SMESH_Mesh theMesh)

Member Function Documentation

SMDS_MeshElement* SMESH_MeshEditor::AddElement ( const std::vector< const SMDS_MeshNode * > &  nodes,
const SMDSAbs_ElementType  type,
const bool  isPoly,
const int  ID = 0 
)

Add element.

SMDS_MeshElement* SMESH_MeshEditor::AddElement ( const std::vector< int > &  nodeIDs,
const SMDSAbs_ElementType  type,
const bool  isPoly,
const int  ID = 0 
)

Add element.

bool SMESH_MeshEditor::Remove ( const std::list< int > &  theElemIDs,
const bool  isNodes 
)
bool SMESH_MeshEditor::InverseDiag ( const SMDS_MeshElement theTria1,
const SMDS_MeshElement theTria2 
)
bool SMESH_MeshEditor::InverseDiag ( const SMDS_MeshNode theNode1,
const SMDS_MeshNode theNode2 
)
bool SMESH_MeshEditor::DeleteDiag ( const SMDS_MeshNode theNode1,
const SMDS_MeshNode theNode2 
)
bool SMESH_MeshEditor::Reorient ( const SMDS_MeshElement theElement)
bool SMESH_MeshEditor::TriToQuad ( TIDSortedElemSet theElems,
SMESH::Controls::NumericalFunctorPtr  theCriterion,
const double  theMaxAngle 
)

Fuse neighbour triangles into quadrangles.

Parameters
theElems- The triangles to be fused.
theCriterion- Is used to choose a neighbour to fuse with.
theMaxAngle- Is a max angle between element normals at which fusion is still performed; theMaxAngle is mesured in radians.
Return values
bool- Success or not.
bool SMESH_MeshEditor::QuadToTri ( TIDSortedElemSet theElems,
SMESH::Controls::NumericalFunctorPtr  theCriterion 
)

Split quadrangles into triangles.

Parameters
theElems- The faces to be splitted.
theCriterion- Is used to choose a diagonal for splitting.
Return values
bool- Success or not.
bool SMESH_MeshEditor::QuadToTri ( TIDSortedElemSet theElems,
const bool  the13Diag 
)

Split quadrangles into triangles.

Parameters
theElems- The faces to be splitted.
the13Diag- Is used to choose a diagonal for splitting.
Return values
bool- Success or not.
int SMESH_MeshEditor::BestSplit ( const SMDS_MeshElement theQuad,
SMESH::Controls::NumericalFunctorPtr  theCriterion 
)

Find better diagonal for splitting.

Parameters
theQuad- The face to find better splitting of.
theCriterion- Is used to choose a diagonal for splitting.
Return values
int- 1 for 1-3 diagonal, 2 for 2-4, -1 - for errors.
void SMESH_MeshEditor::Smooth ( TIDSortedElemSet theElements,
std::set< const SMDS_MeshNode * > &  theFixedNodes,
const SmoothMethod  theSmoothMethod,
const int  theNbIterations,
double  theTgtAspectRatio = 1.0,
const bool  the2D = true 
)
PGroupIDs SMESH_MeshEditor::RotationSweep ( TIDSortedElemSet theElements,
const gp_Ax1 &  theAxis,
const double  theAngle,
const int  theNbSteps,
const double  theToler,
const bool  theMakeGroups,
const bool  theMakeWalls = true 
)
const SMDS_MeshNode* SMESH_MeshEditor::CreateNode ( const double  x,
const double  y,
const double  z,
const double  tolnode,
SMESH_SequenceOfNode &  aNodes 
)

Create new node in the mesh with given coordinates (auxilary for advanced extrusion)

PGroupIDs SMESH_MeshEditor::ExtrusionSweep ( TIDSortedElemSet theElems,
const gp_Vec &  theStep,
const int  theNbSteps,
TElemOfElemListMap newElemsMap,
const bool  theMakeGroups,
const int  theFlags = EXTRUSION_FLAG_BOUNDARY,
const double  theTolerance = 1.e-6 
)

Generate new elements by extrusion of theElements It is a method used in .idl file. All functionality is implemented in the next method (see below) which is used in the cuurent method. param theElems - list of elements for extrusion param newElemsMap returns history of extrusion param theFlags set flags for performing extrusion (see description of enum ExtrusionFlags for additional information) param theTolerance - uses for comparing locations of nodes if flag EXTRUSION_FLAG_SEW is set

PGroupIDs SMESH_MeshEditor::ExtrusionSweep ( TIDSortedElemSet theElems,
ExtrusParam theParams,
TElemOfElemListMap newElemsMap,
const bool  theMakeGroups,
const int  theFlags,
const double  theTolerance 
)

Generate new elements by extrusion of theElements param theElems - list of elements for extrusion param newElemsMap returns history of extrusion param theFlags set flags for performing extrusion (see description of enum ExtrusionFlags for additional information) param theTolerance - uses for comparing locations of nodes if flag EXTRUSION_FLAG_SEW is set param theParams - special structure for manage of extrusion

Extrusion_Error SMESH_MeshEditor::ExtrusionAlongTrack ( TIDSortedElemSet theElements,
SMESH_subMesh theTrackPattern,
const SMDS_MeshNode theNodeStart,
const bool  theHasAngles,
std::list< double > &  theAngles,
const bool  theHasRefPoint,
const gp_Pnt &  theRefPoint,
const bool  theMakeGroups 
)
PGroupIDs SMESH_MeshEditor::Transform ( TIDSortedElemSet theElements,
const gp_Trsf &  theTrsf,
const bool  theCopy,
const bool  theMakeGroups,
SMESH_Mesh theTargetMesh = 0 
)
void SMESH_MeshEditor::FindCoincidentNodes ( std::set< const SMDS_MeshNode * > &  theNodes,
const double  theTolerance,
TListOfListOfNodes theGroupsOfNodes 
)
SMESH_NodeSearcher* SMESH_MeshEditor::GetNodeSearcher ( )
int SMESH_MeshEditor::SimplifyFace ( const std::vector< const SMDS_MeshNode * >  faceNodes,
std::vector< const SMDS_MeshNode * > &  poly_nodes,
std::vector< int > &  quantities 
) const
void SMESH_MeshEditor::MergeNodes ( TListOfListOfNodes theNodeGroups)
void SMESH_MeshEditor::FindEqualElements ( std::set< const SMDS_MeshElement * > &  theElements,
TListOfListOfElementsID theGroupsOfElementsID 
)
void SMESH_MeshEditor::MergeElements ( TListOfListOfElementsID theGroupsOfElementsID)
void SMESH_MeshEditor::MergeEqualElements ( )
static bool SMESH_MeshEditor::CheckFreeBorderNodes ( const SMDS_MeshNode theNode1,
const SMDS_MeshNode theNode2,
const SMDS_MeshNode theNode3 = 0 
)
static
static bool SMESH_MeshEditor::FindFreeBorder ( const SMDS_MeshNode theFirstNode,
const SMDS_MeshNode theSecondNode,
const SMDS_MeshNode theLastNode,
std::list< const SMDS_MeshNode * > &  theNodes,
std::list< const SMDS_MeshElement * > &  theFaces 
)
static
Sew_Error SMESH_MeshEditor::SewFreeBorder ( const SMDS_MeshNode theBorderFirstNode,
const SMDS_MeshNode theBorderSecondNode,
const SMDS_MeshNode theBorderLastNode,
const SMDS_MeshNode theSide2FirstNode,
const SMDS_MeshNode theSide2SecondNode,
const SMDS_MeshNode theSide2ThirdNode = 0,
const bool  theSide2IsFreeBorder = true,
const bool  toCreatePolygons = false,
const bool  toCreatePolyedrs = false 
)
Sew_Error SMESH_MeshEditor::SewSideElements ( TIDSortedElemSet theSide1,
TIDSortedElemSet theSide2,
const SMDS_MeshNode theFirstNode1ToMerge,
const SMDS_MeshNode theFirstNode2ToMerge,
const SMDS_MeshNode theSecondNode1ToMerge,
const SMDS_MeshNode theSecondNode2ToMerge 
)
void SMESH_MeshEditor::InsertNodesIntoLink ( const SMDS_MeshElement theFace,
const SMDS_MeshNode theBetweenNode1,
const SMDS_MeshNode theBetweenNode2,
std::list< const SMDS_MeshNode * > &  theNodesToInsert,
const bool  toCreatePoly = false 
)
void SMESH_MeshEditor::UpdateVolumes ( const SMDS_MeshNode theBetweenNode1,
const SMDS_MeshNode theBetweenNode2,
std::list< const SMDS_MeshNode * > &  theNodesToInsert 
)
void SMESH_MeshEditor::ConvertToQuadratic ( const bool  theForce3d)
bool SMESH_MeshEditor::ConvertFromQuadratic ( )
static void SMESH_MeshEditor::AddToSameGroups ( const SMDS_MeshElement elemToAdd,
const SMDS_MeshElement elemInGroups,
SMESHDS_Mesh aMesh 
)
static
static void SMESH_MeshEditor::RemoveElemFromGroups ( const SMDS_MeshElement element,
SMESHDS_Mesh aMesh 
)
static
static void SMESH_MeshEditor::ReplaceElemInGroups ( const SMDS_MeshElement elemToRm,
const SMDS_MeshElement elemToAdd,
SMESHDS_Mesh aMesh 
)
static
static void SMESH_MeshEditor::GetLinkedNodes ( const SMDS_MeshNode node,
TIDSortedElemSet linkedNodes,
SMDSAbs_ElementType  type = SMDSAbs_All 
)
static

Return nodes linked to the given one in elements of the type.

static const SMDS_MeshElement* SMESH_MeshEditor::FindFaceInSet ( const SMDS_MeshNode n1,
const SMDS_MeshNode n2,
const TIDSortedElemSet elemSet,
const TIDSortedElemSet avoidSet 
)
static
static Sew_Error SMESH_MeshEditor::FindMatchingNodes ( std::set< const SMDS_MeshElement * > &  theSide1,
std::set< const SMDS_MeshElement * > &  theSide2,
const SMDS_MeshNode theFirstNode1,
const SMDS_MeshNode theFirstNode2,
const SMDS_MeshNode theSecondNode1,
const SMDS_MeshNode theSecondNode2,
TNodeNodeMap nReplaceMap 
)
static

Find corresponding nodes in two sets of faces.

Parameters
theSide1- first face set
theSide2- second first face
theFirstNode1- a boundary node of set 1
theFirstNode2- a node of set 2 corresponding to theFirstNode1
theSecondNode1- a boundary node of set 1 linked with theFirstNode1
theSecondNode2- a node of set 2 corresponding to theSecondNode1
nReplaceMap- output map of corresponding nodes
Return values
Sew_Error- is a success or not
static bool SMESH_MeshEditor::IsMedium ( const SMDS_MeshNode node,
const SMDSAbs_ElementType  typeToCheck = SMDSAbs_All 
)
static

Returns true if given node is medium.

Parameters
n- node to check
typeToCheck- type of elements containing the node to ask about node status
Return values
bool- check result
int SMESH_MeshEditor::FindShape ( const SMDS_MeshElement theElem)
SMESH_Mesh* SMESH_MeshEditor::GetMesh ( )

Definition at line 512 of file SMESH_MeshEditor.hxx.

SMESHDS_Mesh* SMESH_MeshEditor::GetMeshDS ( )

Definition at line 514 of file SMESH_MeshEditor.hxx.

const SMESH_SequenceOfElemPtr& SMESH_MeshEditor::GetLastCreatedNodes ( ) const

Definition at line 516 of file SMESH_MeshEditor.hxx.

const SMESH_SequenceOfElemPtr& SMESH_MeshEditor::GetLastCreatedElems ( ) const

Definition at line 518 of file SMESH_MeshEditor.hxx.

bool SMESH_MeshEditor::DoubleNodes ( const std::list< int > &  theListOfNodes,
const std::list< int > &  theListOfModifiedElems 
)
int SMESH_MeshEditor::convertElemToQuadratic ( SMESHDS_SubMesh theSm,
SMESH_MesherHelper theHelper,
const bool  theForce3d 
)
private

Convert elements contained in a submesh to quadratic.

Return values
int- nb of checked elements
int SMESH_MeshEditor::removeQuadElem ( SMESHDS_SubMesh theSm,
SMDS_ElemIteratorPtr  theItr,
const int  theShapeID 
)
private

Convert quadratic elements to linear ones and remove quadratic nodes.

Return values
int- nb of checked elements
PGroupIDs SMESH_MeshEditor::generateGroups ( const SMESH_SequenceOfElemPtr &  nodeGens,
const SMESH_SequenceOfElemPtr &  elemGens,
const std::string &  postfix,
SMESH_Mesh targetMesh = 0 
)
private

Create groups of elements made during transformation.

Parameters
nodeGens- nodes making corresponding myLastCreatedNodes
elemGens- elements making corresponding myLastCreatedElems
postfix- to append to names of new groups
void SMESH_MeshEditor::sweepElement ( const SMDS_MeshElement elem,
const std::vector< TNodeOfNodeListMapItr > &  newNodesItVec,
std::list< const SMDS_MeshElement * > &  newElems,
const int  nbSteps,
SMESH_SequenceOfElemPtr &  srcElements 
)
private

Create elements by sweeping an element.

Parameters
elem- element to sweep
newNodesItVec- nodes generated from each node of the element
newElems- generated elements
nbSteps- number of sweeping steps
srcElements- to append elem for each generated element
void SMESH_MeshEditor::makeWalls ( TNodeOfNodeListMap mapNewNodes,
TElemOfElemListMap newElemsMap,
TElemOfVecOfNnlmiMap elemNewNodesMap,
TIDSortedElemSet elemSet,
const int  nbSteps,
SMESH_SequenceOfElemPtr &  srcElements 
)
private

Create 1D and 2D elements around swept elements.

Parameters
mapNewNodes- source nodes and ones generated from them
newElemsMap- source elements and ones generated from them
elemNewNodesMap- nodes generated from each node of each element
elemSet- all swept elements
nbSteps- number of sweeping steps
srcElements- to append elem for each generated element

Field Documentation

SMESH_Mesh* SMESH_MeshEditor::myMesh
private

Definition at line 588 of file SMESH_MeshEditor.hxx.

SMESH_SequenceOfElemPtr SMESH_MeshEditor::myLastCreatedNodes
private

Sequence for keeping nodes created during last operation

Definition at line 593 of file SMESH_MeshEditor.hxx.

SMESH_SequenceOfElemPtr SMESH_MeshEditor::myLastCreatedElems
private

Sequence for keeping elements created during last operation

Definition at line 598 of file SMESH_MeshEditor.hxx.