#include "SMDS_QuadraticFaceOfNodes.hxx"
#include "SMDS_QuadraticEdge.hxx"
+using namespace std;
+
/*
AUXILIARY METHODS
#define _EDF_NODE_IDS_
using namespace MED;
+using namespace std;
void
DriverMED_R_SMESHDS_Mesh
int myNbPrisms , myNbQuadPrisms ;
int myNbPolyhedrons;
- vector<int*> myNb; // pointers to myNb... fields
- vector<int> myShift; // shift to get an index in myNb by elem->NbNodes()
+ std::vector<int*> myNb; // pointers to myNb... fields
+ std::vector<int> myShift; // shift to get an index in myNb by elem->NbNodes()
};
inline SMDS_MeshInfo::SMDS_MeshInfo():
// Module : SMESH
// $Header$
-using namespace std;
#include "SMESH_2D_Algo.hxx"
#include "SMESH_Gen.hxx"
#include <TopExp.hxx>
#include <TopoDS.hxx>
+using namespace std;
//=============================================================================
/*!
*
// ShapeIndex( ID_Ex00 ) == 0
// ShapeIndex( ID_Ex10 ) == 1
- static void GetFaceEdgesIDs (const int faceID, vector< int >& edgeVec );
+ static void GetFaceEdgesIDs (const int faceID, std::vector< int >& edgeVec );
// return edges IDs of a face in the order u0, u1, 0v, 1v
- static void GetEdgeVertexIDs (const int edgeID, vector< int >& vertexVec );
+ static void GetEdgeVertexIDs (const int edgeID, std::vector< int >& vertexVec );
// return vertex IDs of an edge
static int GetCoordIndOnEdge (const int theEdgeID)
bool LoadMeshBlock(const SMDS_MeshVolume* theVolume,
const int theNode000Index,
const int theNode001Index,
- vector<const SMDS_MeshNode*>& theOrderedNodes);
+ std::vector<const SMDS_MeshNode*>& theOrderedNodes);
// prepare to work with theVolume and
// return nodes in theVolume corners in the order of TShapeID enum
// return coordinates of a point in shell
static bool ShellPoint(const gp_XYZ& theParams,
- const vector<gp_XYZ>& thePointOnShape,
+ const std::vector<gp_XYZ>& thePointOnShape,
gp_XYZ& thePoint );
// computes coordinates of a point in shell by points on sub-shapes
// and point parameters.
gp_XYZ myParam; // the best parameters guess
double myValues[ 4 ]; // values computed at myParam: square distance and 3 derivatives
- typedef pair<gp_XYZ,gp_XYZ> TxyzPair;
+ typedef std::pair<gp_XYZ,gp_XYZ> TxyzPair;
TxyzPair my3x3x3GridNodes[ 27 ]; // to compute the first param guess
bool myGridComputed;
};
std::list <SMESH_subMesh*> _subMeshesUsingHypothesisList;
SMESHDS_Document * _myDocument;
SMESHDS_Mesh * _myMeshDS;
- map <int, SMESH_subMesh *> _mapSubMesh;
- map <int, SMESH_Group *> _mapGroup;
+ std::map <int, SMESH_subMesh *> _mapSubMesh;
+ std::map <int, SMESH_Group *> _mapGroup;
SMESH_Gen * _gen;
bool _isAutoColor;
*/
SMESH_NodeSearcher* GetNodeSearcher();
- int SimplifyFace (const vector<const SMDS_MeshNode *> faceNodes,
- vector<const SMDS_MeshNode *>& poly_nodes,
- vector<int>& quantities) const;
+ int SimplifyFace (const std::vector<const SMDS_MeshNode *> faceNodes,
+ std::vector<const SMDS_MeshNode *>& poly_nodes,
+ std::vector<int>& quantities) const;
// Split face, defined by <faceNodes>, into several faces by repeating nodes.
// Is used by MergeNodes()
* \param nReplaceMap - output map of corresponding nodes
* \retval Sew_Error - is a success or not
*/
- static Sew_Error FindMatchingNodes(set<const SMDS_MeshElement*>& theSide1,
- set<const SMDS_MeshElement*>& theSide2,
+ 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,
#define RETURN_BAD_RESULT(msg) { MESSAGE(msg); return false; }
+using namespace std;
+
//================================================================================
/*!
* \brief Constructor
#include <map>
-typedef pair<const SMDS_MeshNode*, const SMDS_MeshNode*> NLink;
-typedef map<NLink, const SMDS_MeshNode*> NLinkNodeMap;
-typedef map<NLink, const SMDS_MeshNode*>::iterator ItNLinkNode;
+typedef std::pair<const SMDS_MeshNode*, const SMDS_MeshNode*> NLink;
+typedef std::map<NLink, const SMDS_MeshNode*> NLinkNodeMap;
+typedef std::map<NLink, const SMDS_MeshNode*>::iterator ItNLinkNode;
/*!
* \brief It helps meshers to add elements
public:
// Constructor
- SMESH_OctreeNode (const set<const SMDS_MeshNode*>& theNodes, const int maxLevel = -1,
+ SMESH_OctreeNode (const std::set<const SMDS_MeshNode*>& theNodes, const int maxLevel = -1,
const int maxNbNodes = 5 , const double minBoxSize = 0.);
//=============================
virtual const bool isInside(const SMDS_MeshNode * Node, const double precision = 0. );
// Return in Result a list of Nodes potentials to be near Node
- void NodesAround( const SMDS_MeshNode * Node , list<const SMDS_MeshNode*>* Result,
+ void NodesAround( const SMDS_MeshNode * Node ,
+ std::list<const SMDS_MeshNode*>* Result,
const double precision = 0. );
// Return in theGroupsOfNodes a list of group of nodes close to each other within theTolerance
// Search for all the nodes in nodes
- void FindCoincidentNodes ( set<const SMDS_MeshNode*>* nodes,
+ void FindCoincidentNodes ( std::set<const SMDS_MeshNode*>* nodes,
const double theTolerance,
- list< list< const SMDS_MeshNode*> >* theGroupsOfNodes);
+ std::list< std::list< const SMDS_MeshNode*> >* theGroupsOfNodes);
// Static method that return in theGroupsOfNodes a list of group of nodes close to each other within
// theTolerance search for all the nodes in nodes
- static void FindCoincidentNodes ( set<const SMDS_MeshNode*> nodes,
- list< list< const SMDS_MeshNode*> >* theGroupsOfNodes,
+ static void FindCoincidentNodes ( std::set<const SMDS_MeshNode*> nodes,
+ std::list< std::list< const SMDS_MeshNode*> >* theGroupsOfNodes,
const double theTolerance = 0.00001, const int maxLevel = -1,
const int maxNbNodes = 5);
/*!
// Return in result a list of nodes closed to Node and remove it from SetOfNodes
void FindCoincidentNodes( const SMDS_MeshNode * Node,
- set<const SMDS_MeshNode*>* SetOfNodes,
- list<const SMDS_MeshNode*>* Result,
+ std::set<const SMDS_MeshNode*>* SetOfNodes,
+ std::list<const SMDS_MeshNode*>* Result,
const double precision);
// The max number of nodes a leaf box can contain
int myMaxNbNodes;
// The set of nodes inside the box of the Octree (Empty if Octree is not a leaf)
- set<const SMDS_MeshNode*> myNodes;
+ std::set<const SMDS_MeshNode*> myNodes;
// The number of nodes I have inside the box
int myNbNodes;
bool setShapeToMesh(const TopoDS_Shape& theShape);
// Set a shape to be meshed. Return True if meshing is possible
- list< TPoint* > & getShapePoints(const TopoDS_Shape& theShape);
+ std::list< TPoint* > & getShapePoints(const TopoDS_Shape& theShape);
// Return list of points located on theShape.
// A list of edge-points include vertex-points (for 2D pattern only).
// A list of face-points doesnt include edge-points.
// A list of volume-points doesnt include face-points.
- list< TPoint* > & getShapePoints(const int theShapeID);
+ std::list< TPoint* > & getShapePoints(const int theShapeID);
// Return list of points located on the shape
bool findBoundaryPoints();
// If loaded from file, find points to map on edges and faces and
// compute their parameters
- void arrangeBoundaries (list< list< TPoint* > >& boundaryPoints);
+ void arrangeBoundaries (std::list< std::list< TPoint* > >& boundaryPoints);
// if there are several wires, arrange boundaryPoints so that
// the outer wire goes first and fix inner wires orientation;
// update myKeyPointIDs to correspond to the order of key-points
// in boundaries; sort internal boundaries by the nb of key-points
- void computeUVOnEdge( const TopoDS_Edge& theEdge, const list< TPoint* > & ePoints );
+ void computeUVOnEdge( const TopoDS_Edge& theEdge, const std::list< TPoint* > & ePoints );
// compute coordinates of points on theEdge
- bool compUVByIsoIntersection (const list< list< TPoint* > >& boundaryPoints,
+ bool compUVByIsoIntersection (const std::list< std::list< TPoint* > >& boundaryPoints,
const gp_XY& theInitUV,
gp_XY& theUV,
bool & theIsDeformed);
// compute UV by intersection of iso-lines found by points on edges
- bool compUVByElasticIsolines(const list< list< TPoint* > >& boundaryPoints,
- const list< TPoint* >& pointsToCompute);
+ bool compUVByElasticIsolines(const std::list< std::list< TPoint* > >& boundaryPoints,
+ const std::list< TPoint* >& pointsToCompute);
// compute UV as nodes of iso-poly-lines consisting of
// segments keeping relative size as in the pattern
- double setFirstEdge (list< TopoDS_Edge > & theWire, int theFirstEdgeID);
+ double setFirstEdge (std::list< TopoDS_Edge > & theWire, int theFirstEdgeID);
// choose the best first edge of theWire; return the summary distance
// between point UV computed by isolines intersection and
// eventual UV got from edge p-curves
- typedef list< list< TopoDS_Edge > > TListOfEdgesList;
+ typedef std::list< std::list< TopoDS_Edge > > TListOfEdgesList;
bool sortSameSizeWires (TListOfEdgesList & theWireList,
const TListOfEdgesList::iterator& theFromWire,
const TListOfEdgesList::iterator& theToWire,
const int theFirstEdgeID,
- list< list< TPoint* > >& theEdgesPointsList );
+ std::list< std::list< TPoint* > >& theEdgesPointsList );
// sort wires in theWireList from theFromWire until theToWire,
// the wires are set in the order to correspond to the order
// of boundaries; after sorting, edges in the wires are put
// all functions assure that shapes are indexed so that first go
// ordered vertices, then ordered edge, then faces and maybe a shell
TopTools_IndexedMapOfOrientedShape myShapeIDMap;
- std::map< int, list< TPoint* > > myShapeIDToPointsMap;
+ std::map< int, std::list< TPoint* > > myShapeIDToPointsMap;
// for the 2d case:
// nb of key-points in each of pattern boundaries
SMESH_subMesh *GetFirstToCompute();
- const map < int, SMESH_subMesh * >& DependsOn();
+ const std::map < int, SMESH_subMesh * >& DependsOn();
//const map < int, SMESH_subMesh * >&Dependants();
/*!
* \brief Return iterator on the submeshes this one depends on
SMESH_Mesh * _father;
int _Id;
- map < int, SMESH_subMesh * >_mapDepend;
+ std::map < int, SMESH_subMesh * >_mapDepend;
bool _dependenceAnalysed;
int _algoState;
void addNodeToSubmesh( const SMDS_MeshNode* aNode, int Index )
{
//Update or build submesh
- map<int,SMESHDS_SubMesh*>::iterator it = myShapeIndexToSubMesh.find( Index );
+ std::map<int,SMESHDS_SubMesh*>::iterator it = myShapeIndexToSubMesh.find( Index );
if ( it == myShapeIndexToSubMesh.end() )
- it = myShapeIndexToSubMesh.insert( make_pair(Index, new SMESHDS_SubMesh() )).first;
+ it = myShapeIndexToSubMesh.insert( std::make_pair(Index, new SMESHDS_SubMesh() )).first;
it->second->AddNode( aNode ); // add aNode to submesh
}