SALOME - SMESH
|
Tool analyzing and giving access to a prism geometry treating it like a block, i.e. the four side faces are emulated by division/uniting of missing/excess faces. It also manage associations between block subshapes and a mesh. More...
#include <StdMeshers_Prism_3D.hxx>
Data Structures | |
class | THorizontalEdgeAdaptor |
Class emulating geometry of a hirizontal edge. More... | |
class | TPCurveOnHorFaceAdaptor |
Class emulating pcurve on a hirizontal face. More... | |
class | TSideFace |
Class representing a part of a geom face or a union of seleral faces. Or just an ordinary geom face. More... | |
class | TVerticalEdgeAdaptor |
Class emulating geometry of a vertical edge. More... | |
Public Types | |
enum | TShapeID { ID_NONE = 0, ID_V000 = 1, ID_V100, ID_V010, ID_V110, ID_V001, ID_V101, ID_V011, ID_V111, ID_Ex00, ID_Ex10, ID_Ex01, ID_Ex11, ID_E0y0, ID_E1y0, ID_E0y1, ID_E1y1, ID_E00z, ID_E10z, ID_E01z, ID_E11z, ID_Fxy0, ID_Fxy1, ID_Fx0z, ID_Fx1z, ID_F0yz, ID_F1yz, ID_Shell } |
enum | { ID_FirstV = ID_V000, ID_FirstE = ID_Ex00, ID_FirstF = ID_Fxy0 } |
Public Member Functions | |
StdMeshers_PrismAsBlock () | |
Constructor. Initialization is needed. | |
~StdMeshers_PrismAsBlock () | |
bool | Init (SMESH_MesherHelper *helper, const TopoDS_Shape &shape3D) |
Initialization. | |
SMESH_ComputeErrorPtr | GetError () const |
Return problem description. | |
int | VerticalSize () const |
Return number of nodes on every vertical edge. | |
bool | HasNotQuadElemOnTop () const |
const TNodeColumn * | GetNodeColumn (const SMDS_MeshNode *node) const |
Return pointer to column of nodes. | |
const TParam2ColumnMap & | GetParam2ColumnMap (const int baseEdgeID, bool &isReverse) |
Return TParam2ColumnMap for a base edge. | |
SMESH_Mesh * | Mesh () const |
Return pointer to mesh. | |
SMESHDS_Mesh * | MeshDS () const |
Return pointer to mesh DS. | |
SMESH_subMesh * | SubMesh (const int shapeID) const |
Return submesh of a shape. | |
SMESHDS_SubMesh * | SubMeshDS (const int shapeID) const |
Return submesh DS of a shape. | |
const TopoDS_Shape & | Shape (const int shapeID) const |
Return a in-block shape. | |
int | ShapeID (const TopoDS_Shape &shape) const |
Return in-block ID of a shape. | |
bool | LoadBlockShapes (const TopoDS_Shell &theShell, const TopoDS_Vertex &theVertex000, const TopoDS_Vertex &theVertex001, TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
bool | LoadBlockShapes (const TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
bool | LoadMeshBlock (const SMDS_MeshVolume *theVolume, const int theNode000Index, const int theNode001Index, std::vector< const SMDS_MeshNode * > &theOrderedNodes) |
bool | LoadFace (const TopoDS_Face &theFace, const int theFaceID, const TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
bool | VertexPoint (const int theVertexID, gp_XYZ &thePoint) const |
bool | EdgePoint (const int theEdgeID, const gp_XYZ &theParams, gp_XYZ &thePoint) const |
bool | EdgeU (const int theEdgeID, const gp_XYZ &theParams, double &theU) const |
bool | FacePoint (const int theFaceID, const gp_XYZ &theParams, gp_XYZ &thePoint) const |
bool | FaceUV (const int theFaceID, const gp_XYZ &theParams, gp_XY &theUV) const |
bool | ShellPoint (const gp_XYZ &theParams, gp_XYZ &thePoint) const |
bool | ComputeParameters (const gp_Pnt &thePoint, gp_XYZ &theParams, const int theShapeID=ID_Shell, const gp_XYZ &theParamsHint=gp_XYZ(-1,-1,-1)) |
bool | VertexParameters (const int theVertexID, gp_XYZ &theParams) |
bool | EdgeParameters (const int theEdgeID, const double theU, gp_XYZ &theParams) |
Standard_Integer | NbVariables () const |
Standard_Integer | NbEquations () const |
Standard_Boolean | Value (const math_Vector &X, math_Vector &F) |
Standard_Boolean | Derivatives (const math_Vector &X, math_Matrix &D) |
Standard_Boolean | Values (const math_Vector &X, math_Vector &F, math_Matrix &D) |
Standard_Integer | GetStateNumber () |
Static Public Member Functions | |
static bool | IsForwardEdge (SMESHDS_Mesh *meshDS, const TParam2ColumnMap &columnsMap, const TopoDS_Edge &bottomEdge, const int sideFaceID) |
Check curve orientation of a bootom edge. | |
static bool | GetWallFaces (SMESH_Mesh *mesh, const TopoDS_Shape &mainShape, const TopoDS_Shape &bottomFace, const std::list< TopoDS_Edge > &bottomEdges, std::list< TopoDS_Face > &wallFaces) |
Find wall faces by bottom edges. | |
static int | NbVertices () |
static int | NbEdges () |
static int | NbFaces () |
static int | NbSubShapes () |
static bool | IsVertexID (int theShapeID) |
static bool | IsEdgeID (int theShapeID) |
static bool | IsFaceID (int theShapeID) |
static int | ShapeIndex (int theShapeID) |
static void | GetFaceEdgesIDs (const int faceID, std::vector< int > &edgeVec) |
static void | GetEdgeVertexIDs (const int edgeID, std::vector< int > &vertexVec) |
static int | GetCoordIndOnEdge (const int theEdgeID) |
static double * | GetShapeCoef (const int theShapeID) |
static int | GetShapeIDByParams (const gp_XYZ &theParams) |
static std::ostream & | DumpShapeID (const int theBlockShapeID, std::ostream &stream) |
static bool | Insert (const TopoDS_Shape &theShape, const int theShapeID, TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
static bool | FindBlockShapes (const TopoDS_Shell &theShell, const TopoDS_Vertex &theVertex000, const TopoDS_Vertex &theVertex001, TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
static bool | ShellPoint (const gp_XYZ &theParams, const std::vector< gp_XYZ > &thePointOnShape, gp_XYZ &thePoint) |
static bool | IsForwardEdge (const TopoDS_Edge &theEdge, const TopTools_IndexedMapOfOrientedShape &theShapeIDMap) |
static int | GetOrderedEdges (const TopoDS_Face &theFace, TopoDS_Vertex theFirstVertex, std::list< TopoDS_Edge > &theEdges, std::list< int > &theNbVertexInWires, const bool theShapeAnalysisAlgo=false) |
Protected Types | |
enum | { SQUARE_DIST = 0, DRV_1, DRV_2, DRV_3 } |
typedef std::pair< gp_XYZ, gp_XYZ > | TxyzPair |
Protected Member Functions | |
void | init () |
Call it after geometry initialisation. | |
double | distance () const |
double | funcValue (double sqDist) const |
bool | computeParameters (const gp_Pnt &thePoint, gp_XYZ &theParams, const gp_XYZ &theParamsHint) |
Protected Attributes | |
gp_XYZ | myPnt [8] |
TEdge | myEdge [12] |
TFace | myFace [6] |
int | myFaceIndex |
double | myFaceParam |
int | myNbIterations |
double | mySumDist |
double | myTolerance |
bool | mySquareFunc |
gp_XYZ | myPoint |
gp_XYZ | myParam |
double | myValues [4] |
TxyzPair | my3x3x3GridNodes [27] |
bool | myGridComputed |
Private Member Functions | |
bool | error (int error, const SMESH_Comment &comment="") |
store error and comment and then return ( error == COMPERR_OK ) | |
Private Attributes | |
bool | myNotQuadOnTop |
SMESH_MesherHelper * | myHelper |
TBlockShapes | myShapeIDMap |
TSideFace * | mySide |
std::vector< TParam2ColumnMap > | myParam2ColumnMaps |
std::map< int, std::pair < TParam2ColumnMap *, bool > > | myShapeIndex2ColumnMap |
SMESH_ComputeErrorPtr | myError |
Tool analyzing and giving access to a prism geometry treating it like a block, i.e. the four side faces are emulated by division/uniting of missing/excess faces. It also manage associations between block subshapes and a mesh.
Definition at line 99 of file StdMeshers_Prism_3D.hxx.
typedef std::pair<gp_XYZ,gp_XYZ> SMESH_Block::TxyzPair [protected, inherited] |
Definition at line 384 of file SMESH_Block.hxx.
enum SMESH_Block::TShapeID [inherited] |
Definition at line 64 of file SMESH_Block.hxx.
anonymous enum [inherited] |
Definition at line 80 of file SMESH_Block.hxx.
anonymous enum [protected, inherited] |
Definition at line 368 of file SMESH_Block.hxx.
Constructor. Initialization is needed.
bool StdMeshers_PrismAsBlock::Init | ( | SMESH_MesherHelper * | helper, |
const TopoDS_Shape & | shape3D | ||
) |
Initialization.
helper | - helper loaded with mesh and 3D shape |
shape3D | - a closed shell or solid |
bool | - false if a mesh or a shape are KO |
Analyse shape geometry and mesh. If there are triangles on one of faces, it becomes 'bottom'
Return problem description.
Definition at line 123 of file StdMeshers_Prism_3D.hxx.
int StdMeshers_PrismAsBlock::VerticalSize | ( | ) | const |
Return number of nodes on every vertical edge.
int | - number of nodes including end nodes |
Definition at line 129 of file StdMeshers_Prism_3D.hxx.
bool StdMeshers_PrismAsBlock::HasNotQuadElemOnTop | ( | ) | const |
Definition at line 131 of file StdMeshers_Prism_3D.hxx.
const TNodeColumn* StdMeshers_PrismAsBlock::GetNodeColumn | ( | const SMDS_MeshNode * | node | ) | const |
Return pointer to column of nodes.
node | - bottom node from which the returned column goes up |
const | TNodeColumn* - the found column |
const TParam2ColumnMap& StdMeshers_PrismAsBlock::GetParam2ColumnMap | ( | const int | baseEdgeID, |
bool & | isReverse | ||
) |
Return TParam2ColumnMap for a base edge.
baseEdgeID | - base edge SMESHDS Index |
isReverse | - columns in-block orientation |
const | TParam2ColumnMap& - map |
Definition at line 146 of file StdMeshers_Prism_3D.hxx.
SMESH_Mesh* StdMeshers_PrismAsBlock::Mesh | ( | ) | const |
Return pointer to mesh.
SMESH_Mesh | - mesh |
Definition at line 159 of file StdMeshers_Prism_3D.hxx.
SMESHDS_Mesh* StdMeshers_PrismAsBlock::MeshDS | ( | ) | const |
Return pointer to mesh DS.
SMESHDS_Mesh | - mesh DS |
Definition at line 165 of file StdMeshers_Prism_3D.hxx.
SMESH_subMesh* StdMeshers_PrismAsBlock::SubMesh | ( | const int | shapeID | ) | const |
Return submesh of a shape.
shapeID | - shape given by in-block index |
SMESH_subMesh* | - found submesh |
Definition at line 172 of file StdMeshers_Prism_3D.hxx.
SMESHDS_SubMesh* StdMeshers_PrismAsBlock::SubMeshDS | ( | const int | shapeID | ) | const |
Return submesh DS of a shape.
shapeID | - shape given by in-block index |
SMESHDS_SubMesh* | - found submesh DS |
Definition at line 180 of file StdMeshers_Prism_3D.hxx.
const TopoDS_Shape& StdMeshers_PrismAsBlock::Shape | ( | const int | shapeID | ) | const |
Return a in-block shape.
shapeID | - shape given by in-block index |
SMESHDS_SubMesh* | - found submesh |
Definition at line 188 of file StdMeshers_Prism_3D.hxx.
int StdMeshers_PrismAsBlock::ShapeID | ( | const TopoDS_Shape & | shape | ) | const |
Return in-block ID of a shape.
shape | - block subshape |
int | - ID or zero if the shape has no ID |
Definition at line 196 of file StdMeshers_Prism_3D.hxx.
static bool StdMeshers_PrismAsBlock::IsForwardEdge | ( | SMESHDS_Mesh * | meshDS, |
const TParam2ColumnMap & | columnsMap, | ||
const TopoDS_Edge & | bottomEdge, | ||
const int | sideFaceID | ||
) | [static] |
Check curve orientation of a bootom edge.
meshDS | - mesh DS |
columnsMap | - node columns map of side face |
bottomEdge | - the bootom edge |
sideFaceID | - side face in-block ID |
bool | - true if orienation coinside with in-block froward orienation |
static bool StdMeshers_PrismAsBlock::GetWallFaces | ( | SMESH_Mesh * | mesh, |
const TopoDS_Shape & | mainShape, | ||
const TopoDS_Shape & | bottomFace, | ||
const std::list< TopoDS_Edge > & | bottomEdges, | ||
std::list< TopoDS_Face > & | wallFaces | ||
) | [static] |
Find wall faces by bottom edges.
mesh | - the mesh |
mainShape | - the prism |
bottomFace | - the bottom face |
bottomEdges | - edges bounding the bottom face |
wallFaces | - faces list to fill in |
bool StdMeshers_PrismAsBlock::error | ( | int | error, |
const SMESH_Comment & | comment = "" |
||
) | [private] |
store error and comment and then return ( error == COMPERR_OK )
Definition at line 357 of file StdMeshers_Prism_3D.hxx.
References SMESH_ComputeError::New().
static int SMESH_Block::NbVertices | ( | ) | [static, inherited] |
Definition at line 92 of file SMESH_Block.hxx.
static int SMESH_Block::NbEdges | ( | ) | [static, inherited] |
Definition at line 93 of file SMESH_Block.hxx.
static int SMESH_Block::NbFaces | ( | ) | [static, inherited] |
Definition at line 94 of file SMESH_Block.hxx.
static int SMESH_Block::NbSubShapes | ( | ) | [static, inherited] |
Definition at line 95 of file SMESH_Block.hxx.
static bool SMESH_Block::IsVertexID | ( | int | theShapeID | ) | [static, inherited] |
Definition at line 98 of file SMESH_Block.hxx.
static bool SMESH_Block::IsEdgeID | ( | int | theShapeID | ) | [static, inherited] |
Definition at line 101 of file SMESH_Block.hxx.
static bool SMESH_Block::IsFaceID | ( | int | theShapeID | ) | [static, inherited] |
Definition at line 104 of file SMESH_Block.hxx.
static int SMESH_Block::ShapeIndex | ( | int | theShapeID | ) | [static, inherited] |
Definition at line 107 of file SMESH_Block.hxx.
static void SMESH_Block::GetFaceEdgesIDs | ( | const int | faceID, |
std::vector< int > & | edgeVec | ||
) | [static, inherited] |
static void SMESH_Block::GetEdgeVertexIDs | ( | const int | edgeID, |
std::vector< int > & | vertexVec | ||
) | [static, inherited] |
static int SMESH_Block::GetCoordIndOnEdge | ( | const int | theEdgeID | ) | [static, inherited] |
Definition at line 125 of file SMESH_Block.hxx.
static double* SMESH_Block::GetShapeCoef | ( | const int | theShapeID | ) | [static, inherited] |
static int SMESH_Block::GetShapeIDByParams | ( | const gp_XYZ & | theParams | ) | [static, inherited] |
static std::ostream& SMESH_Block::DumpShapeID | ( | const int | theBlockShapeID, |
std::ostream & | stream | ||
) | [static, inherited] |
bool SMESH_Block::LoadBlockShapes | ( | const TopoDS_Shell & | theShell, |
const TopoDS_Vertex & | theVertex000, | ||
const TopoDS_Vertex & | theVertex001, | ||
TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ||
) | [inherited] |
bool SMESH_Block::LoadBlockShapes | ( | const TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ) | [inherited] |
bool SMESH_Block::LoadMeshBlock | ( | const SMDS_MeshVolume * | theVolume, |
const int | theNode000Index, | ||
const int | theNode001Index, | ||
std::vector< const SMDS_MeshNode * > & | theOrderedNodes | ||
) | [inherited] |
bool SMESH_Block::LoadFace | ( | const TopoDS_Face & | theFace, |
const int | theFaceID, | ||
const TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ||
) | [inherited] |
static bool SMESH_Block::Insert | ( | const TopoDS_Shape & | theShape, |
const int | theShapeID, | ||
TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ||
) | [static, inherited] |
static bool SMESH_Block::FindBlockShapes | ( | const TopoDS_Shell & | theShell, |
const TopoDS_Vertex & | theVertex000, | ||
const TopoDS_Vertex & | theVertex001, | ||
TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ||
) | [static, inherited] |
bool SMESH_Block::VertexPoint | ( | const int | theVertexID, |
gp_XYZ & | thePoint | ||
) | const [inherited] |
Definition at line 195 of file SMESH_Block.hxx.
bool SMESH_Block::EdgePoint | ( | const int | theEdgeID, |
const gp_XYZ & | theParams, | ||
gp_XYZ & | thePoint | ||
) | const [inherited] |
Definition at line 201 of file SMESH_Block.hxx.
bool SMESH_Block::EdgeU | ( | const int | theEdgeID, |
const gp_XYZ & | theParams, | ||
double & | theU | ||
) | const [inherited] |
Definition at line 207 of file SMESH_Block.hxx.
bool SMESH_Block::FacePoint | ( | const int | theFaceID, |
const gp_XYZ & | theParams, | ||
gp_XYZ & | thePoint | ||
) | const [inherited] |
Definition at line 213 of file SMESH_Block.hxx.
bool SMESH_Block::FaceUV | ( | const int | theFaceID, |
const gp_XYZ & | theParams, | ||
gp_XY & | theUV | ||
) | const [inherited] |
Definition at line 219 of file SMESH_Block.hxx.
bool SMESH_Block::ShellPoint | ( | const gp_XYZ & | theParams, |
gp_XYZ & | thePoint | ||
) | const [inherited] |
static bool SMESH_Block::ShellPoint | ( | const gp_XYZ & | theParams, |
const std::vector< gp_XYZ > & | thePointOnShape, | ||
gp_XYZ & | thePoint | ||
) | [static, inherited] |
bool SMESH_Block::ComputeParameters | ( | const gp_Pnt & | thePoint, |
gp_XYZ & | theParams, | ||
const int | theShapeID = ID_Shell , |
||
const gp_XYZ & | theParamsHint = gp_XYZ(-1,-1,-1) |
||
) | [inherited] |
bool SMESH_Block::VertexParameters | ( | const int | theVertexID, |
gp_XYZ & | theParams | ||
) | [inherited] |
bool SMESH_Block::EdgeParameters | ( | const int | theEdgeID, |
const double | theU, | ||
gp_XYZ & | theParams | ||
) | [inherited] |
static bool SMESH_Block::IsForwardEdge | ( | const TopoDS_Edge & | theEdge, |
const TopTools_IndexedMapOfOrientedShape & | theShapeIDMap | ||
) | [static, inherited] |
Definition at line 268 of file SMESH_Block.hxx.
static int SMESH_Block::GetOrderedEdges | ( | const TopoDS_Face & | theFace, |
TopoDS_Vertex | theFirstVertex, | ||
std::list< TopoDS_Edge > & | theEdges, | ||
std::list< int > & | theNbVertexInWires, | ||
const bool | theShapeAnalysisAlgo = false |
||
) | [static, inherited] |
Standard_Integer SMESH_Block::NbVariables | ( | ) | const [inherited] |
Standard_Integer SMESH_Block::NbEquations | ( | ) | const [inherited] |
Standard_Boolean SMESH_Block::Value | ( | const math_Vector & | X, |
math_Vector & | F | ||
) | [inherited] |
Standard_Boolean SMESH_Block::Derivatives | ( | const math_Vector & | X, |
math_Matrix & | D | ||
) | [inherited] |
Standard_Boolean SMESH_Block::Values | ( | const math_Vector & | X, |
math_Vector & | F, | ||
math_Matrix & | D | ||
) | [inherited] |
Standard_Integer SMESH_Block::GetStateNumber | ( | ) | [inherited] |
void SMESH_Block::init | ( | ) | [protected, inherited] |
Call it after geometry initialisation.
double SMESH_Block::distance | ( | ) | const [protected, inherited] |
Definition at line 369 of file SMESH_Block.hxx.
double SMESH_Block::funcValue | ( | double | sqDist | ) | const [protected, inherited] |
Definition at line 370 of file SMESH_Block.hxx.
bool SMESH_Block::computeParameters | ( | const gp_Pnt & | thePoint, |
gp_XYZ & | theParams, | ||
const gp_XYZ & | theParamsHint | ||
) | [protected, inherited] |
bool StdMeshers_PrismAsBlock::myNotQuadOnTop [private] |
Definition at line 342 of file StdMeshers_Prism_3D.hxx.
Definition at line 343 of file StdMeshers_Prism_3D.hxx.
Definition at line 344 of file StdMeshers_Prism_3D.hxx.
TSideFace* StdMeshers_PrismAsBlock::mySide [private] |
Definition at line 347 of file StdMeshers_Prism_3D.hxx.
std::vector< TParam2ColumnMap > StdMeshers_PrismAsBlock::myParam2ColumnMaps [private] |
Definition at line 349 of file StdMeshers_Prism_3D.hxx.
std::map< int, std::pair< TParam2ColumnMap*, bool > > StdMeshers_PrismAsBlock::myShapeIndex2ColumnMap [private] |
Definition at line 351 of file StdMeshers_Prism_3D.hxx.
Definition at line 353 of file StdMeshers_Prism_3D.hxx.
gp_XYZ SMESH_Block::myPnt[8] [protected, inherited] |
Definition at line 360 of file SMESH_Block.hxx.
TEdge SMESH_Block::myEdge[12] [protected, inherited] |
Definition at line 362 of file SMESH_Block.hxx.
TFace SMESH_Block::myFace[6] [protected, inherited] |
Definition at line 364 of file SMESH_Block.hxx.
int SMESH_Block::myFaceIndex [protected, inherited] |
Definition at line 373 of file SMESH_Block.hxx.
double SMESH_Block::myFaceParam [protected, inherited] |
Definition at line 374 of file SMESH_Block.hxx.
int SMESH_Block::myNbIterations [protected, inherited] |
Definition at line 375 of file SMESH_Block.hxx.
double SMESH_Block::mySumDist [protected, inherited] |
Definition at line 376 of file SMESH_Block.hxx.
double SMESH_Block::myTolerance [protected, inherited] |
Definition at line 377 of file SMESH_Block.hxx.
bool SMESH_Block::mySquareFunc [protected, inherited] |
Definition at line 378 of file SMESH_Block.hxx.
gp_XYZ SMESH_Block::myPoint [protected, inherited] |
Definition at line 380 of file SMESH_Block.hxx.
gp_XYZ SMESH_Block::myParam [protected, inherited] |
Definition at line 381 of file SMESH_Block.hxx.
double SMESH_Block::myValues[4] [protected, inherited] |
Definition at line 382 of file SMESH_Block.hxx.
TxyzPair SMESH_Block::my3x3x3GridNodes[27] [protected, inherited] |
Definition at line 385 of file SMESH_Block.hxx.
bool SMESH_Block::myGridComputed [protected, inherited] |
Definition at line 386 of file SMESH_Block.hxx.