42cf5bc1 |
1 | // Created on: 1992-08-11 |
2 | // Created by: Remi LEQUETTE |
3 | // Copyright (c) 1992-1999 Matra Datavision |
4 | // Copyright (c) 1999-2014 OPEN CASCADE SAS |
5 | // |
6 | // This file is part of Open CASCADE Technology software library. |
7 | // |
8 | // This library is free software; you can redistribute it and/or modify it under |
9 | // the terms of the GNU Lesser General Public License version 2.1 as published |
10 | // by the Free Software Foundation, with special exception defined in the file |
11 | // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT |
12 | // distribution for complete text of the license and disclaimer of any warranty. |
13 | // |
14 | // Alternatively, this file may be used under the terms of Open CASCADE |
15 | // commercial license or contractual agreement. |
16 | |
17 | #ifndef _TopCnx_EdgeFaceTransition_HeaderFile |
18 | #define _TopCnx_EdgeFaceTransition_HeaderFile |
19 | |
20 | #include <Standard.hxx> |
21 | #include <Standard_DefineAlloc.hxx> |
22 | #include <Standard_Handle.hxx> |
23 | |
24 | #include <TopTrans_CurveTransition.hxx> |
25 | #include <Standard_Integer.hxx> |
26 | #include <Standard_Real.hxx> |
27 | #include <TopAbs_Orientation.hxx> |
28 | class gp_Dir; |
29 | |
30 | |
31 | //! TheEdgeFaceTransition is an algorithm to compute |
32 | //! the cumulated transition for interferences on an |
33 | //! edge. |
34 | class TopCnx_EdgeFaceTransition |
35 | { |
36 | public: |
37 | |
38 | DEFINE_STANDARD_ALLOC |
39 | |
40 | |
41 | //! Creates an empty algorithm. |
42 | Standard_EXPORT TopCnx_EdgeFaceTransition(); |
43 | |
44 | //! Initialize the algorithm with the local |
45 | //! description of the edge. |
46 | Standard_EXPORT void Reset (const gp_Dir& Tgt, const gp_Dir& Norm, const Standard_Real Curv); |
47 | |
48 | //! Initialize the algorithm with a linear Edge. |
49 | Standard_EXPORT void Reset (const gp_Dir& Tgt); |
50 | |
51 | //! Add a curve element to the boundary. Or is the |
52 | //! orientation of the interference on the boundary |
53 | //! curve. Tr is the transition of the interference. |
54 | //! BTr is the boundary transition of the |
55 | //! interference. |
56 | Standard_EXPORT void AddInterference (const Standard_Real Tole, const gp_Dir& Tang, const gp_Dir& Norm, const Standard_Real Curv, const TopAbs_Orientation Or, const TopAbs_Orientation Tr, const TopAbs_Orientation BTr); |
57 | |
58 | //! Returns the current cumulated transition. |
59 | Standard_EXPORT TopAbs_Orientation Transition() const; |
60 | |
61 | //! Returns the current cumulated BoundaryTransition. |
62 | Standard_EXPORT TopAbs_Orientation BoundaryTransition() const; |
63 | |
64 | |
65 | |
66 | |
67 | protected: |
68 | |
69 | |
70 | |
71 | |
72 | |
73 | private: |
74 | |
75 | |
76 | |
77 | TopTrans_CurveTransition myCurveTransition; |
78 | Standard_Integer nbBoundForward; |
79 | Standard_Integer nbBoundReversed; |
80 | |
81 | |
82 | }; |
83 | |
84 | |
85 | |
86 | |
87 | |
88 | |
89 | |
90 | #endif // _TopCnx_EdgeFaceTransition_HeaderFile |