Salome HOME
Get altitude from region implementation.
[modules/hydro.git] / src / HYDROData / HYDROData_Pipes.h
1
2 #ifndef HYDROData_Pipes_HeaderFile
3 #define HYDROData_Pipes_HeaderFile
4
5 #include <TopoDS_Vertex.hxx>
6 #include <TopoDS_Wire.hxx>
7 #include <gp_Pnt.hxx>
8 #include <TopTools_ListOfShape.hxx>
9 #include <ShapeUpgrade_UnifySameDomain.hxx>
10
11 class BRepOffsetAPI_MakePipeShell;
12 class TopoDS_Face;
13
14 class HYDROData_Canal3dAnd2d
15 {
16 public:
17   HYDROData_Canal3dAnd2d( const TopoDS_Wire& Profile,
18                           const TopoDS_Wire& Guideline );
19   
20   Standard_Boolean Create3dPresentation();
21
22   Standard_Boolean Create2dPresentation();
23
24   Standard_Boolean ProjectWireOntoXOY(const TopoDS_Wire& aWire,
25                                       TopoDS_Wire& ProjectedWire);
26
27   void Make2dProfile();
28
29   TopoDS_Vertex ProjectVertexOntoXOY(const TopoDS_Vertex& aVertex);
30
31   void SetMiddlePoint2d();
32
33   void SetMiddlePoint3d();
34
35   TopoDS_Wire SetTransformedProfile(const TopoDS_Wire& aProfile,
36                                     const TopoDS_Wire& aGuideline,
37                                     const gp_Pnt& aMiddlePoint);
38
39   TopoDS_Wire CreateWireOnUnifiedPipe2d(const TopoDS_Wire& aWireOnPipe2d);
40
41   TopoDS_Wire GetBank(const TopoDS_Vertex& aFreeVertex);
42
43   //Queries
44   TopoDS_Shape Get3dPresentation();
45   TopoDS_Face  Get2dPresentation();
46   TopoDS_Wire GetLeftBank();
47   TopoDS_Wire GetRightBank();
48   TopoDS_Wire GetInlet();
49   TopoDS_Wire GetOutlet();
50
51   void MakeSharpVertexList();
52
53   Standard_Boolean MakeFillet();
54
55 private:
56
57   TopoDS_Wire myProfile;
58   TopoDS_Wire myGuideline;
59   TopoDS_Vertex myLeftVertex;
60   TopoDS_Vertex myRightVertex;
61   TopoDS_Vertex myLeftVertex2d;
62   TopoDS_Vertex myRightVertex2d;
63   gp_Pnt myMiddlePoint2d;
64   gp_Pnt myMiddlePoint3d;
65
66   TopoDS_Wire myProjectedProfile;
67   TopoDS_Wire myProjectedGuideline, myOriginalGuideline;
68   TopoDS_Wire myTransformedProfile3d;
69   TopoDS_Wire myTransformedProfile2d;
70   BRepOffsetAPI_MakePipeShell* mySweep3d;
71   BRepOffsetAPI_MakePipeShell* mySweep2d;
72
73   TopoDS_Shape myPipe3d;
74   TopoDS_Shape myPipe2d;
75   TopoDS_Shape myUnifiedPipe2d;
76   ShapeUpgrade_UnifySameDomain myUnifier;
77   TopoDS_Wire myInlet;
78   TopoDS_Wire myOutlet;
79   //TopoDS_Shape myLeftBank;
80   //TopoDS_Shape myRightBank;
81
82   Standard_Real myFilletRadius;
83   TopTools_ListOfShape mySharpVertexList;
84   Standard_Real myTolAngular;
85 };
86
87 #endif