Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _SMESH_QuadToTriaAdaptor_HXX_
00025 #define _SMESH_QuadToTriaAdaptor_HXX_
00026
00027 #include "SMESH_StdMeshers.hxx"
00028
00029 #include "SMESH_ProxyMesh.hxx"
00030
00031 class SMESH_Mesh;
00032 class SMESH_ElementSearcher;
00033 class SMDS_MeshElement;
00034 class SMDS_MeshNode;
00035 class SMDS_MeshFace;
00036 class Handle_TColgp_HArray1OfPnt;
00037 class Handle_TColgp_HArray1OfVec;
00038 class gp_Pnt;
00039 class gp_Vec;
00040
00041
00042 #include <set>
00043 #include <list>
00044 #include <vector>
00045
00046 #include <TopoDS_Shape.hxx>
00047
00051 class STDMESHERS_EXPORT StdMeshers_QuadToTriaAdaptor : public SMESH_ProxyMesh
00052 {
00053 public:
00054 StdMeshers_QuadToTriaAdaptor();
00055
00056 ~StdMeshers_QuadToTriaAdaptor();
00057
00058 bool Compute(SMESH_Mesh& aMesh,
00059 const TopoDS_Shape& aShape,
00060 SMESH_ProxyMesh* aProxyMesh=0);
00061
00062 bool Compute(SMESH_Mesh& aMesh);
00063
00064 protected:
00065
00066 int Preparation(const SMDS_MeshElement* face,
00067 Handle_TColgp_HArray1OfPnt& PN,
00068 Handle_TColgp_HArray1OfVec& VN,
00069 std::vector<const SMDS_MeshNode*>& FNodes,
00070 gp_Pnt& PC, gp_Vec& VNorm,
00071 const SMDS_MeshElement** volumes=0);
00072
00073 bool CheckIntersection(const gp_Pnt& P, const gp_Pnt& PC,
00074 gp_Pnt& Pint, SMESH_Mesh& aMesh,
00075 const TopoDS_Shape& aShape,
00076 const SMDS_MeshElement* NotCheckedFace);
00077
00078 bool Compute2ndPart(SMESH_Mesh& aMesh,
00079 const std::vector<const SMDS_MeshElement*>& pyramids);
00080
00081
00082 void MergePiramids( const SMDS_MeshElement* PrmI,
00083 const SMDS_MeshElement* PrmJ,
00084 std::set<const SMDS_MeshNode*> & nodesToMove);
00085
00086 void MergeAdjacent(const SMDS_MeshElement* PrmI,
00087 std::set<const SMDS_MeshNode*>& nodesToMove);
00088
00089
00090 std::set<const SMDS_MeshElement*> myRemovedTrias;
00091
00092 std::list< const SMDS_MeshNode* > myDegNodes;
00093
00094 const SMESH_ElementSearcher* myElemSearcher;
00095 };
00096
00097 #endif