summaryrefslogtreecommitdiff
path: root/inc/BRepIntCurveSurface_Inter.hxx
blob: a63e9e3e28d722bd71532731945c3e88ed2b755a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
// This file is generated by WOK (CPPExt).
// Please do not edit this file; modify original file instead.
// The copyright and license terms as defined for the original file apply to 
// this header file considered to be the "object code" form of the original source.

#ifndef _BRepIntCurveSurface_Inter_HeaderFile
#define _BRepIntCurveSurface_Inter_HeaderFile

#ifndef _Standard_HeaderFile
#include <Standard.hxx>
#endif
#ifndef _Standard_Macro_HeaderFile
#include <Standard_Macro.hxx>
#endif

#ifndef _Standard_Boolean_HeaderFile
#include <Standard_Boolean.hxx>
#endif
#ifndef _Standard_Real_HeaderFile
#include <Standard_Real.hxx>
#endif
#ifndef _gp_Lin_HeaderFile
#include <gp_Lin.hxx>
#endif
#ifndef _GeomAdaptor_Curve_HeaderFile
#include <GeomAdaptor_Curve.hxx>
#endif
#ifndef _TopExp_Explorer_HeaderFile
#include <TopExp_Explorer.hxx>
#endif
#ifndef _BRepClass_FaceClassifier_HeaderFile
#include <BRepClass_FaceClassifier.hxx>
#endif
#ifndef _IntCurveSurface_HInter_HeaderFile
#include <IntCurveSurface_HInter.hxx>
#endif
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
#ifndef _Handle_BRepTopAdaptor_TopolTool_HeaderFile
#include <Handle_BRepTopAdaptor_TopolTool.hxx>
#endif
#ifndef _Handle_BRepAdaptor_HSurface_HeaderFile
#include <Handle_BRepAdaptor_HSurface.hxx>
#endif
#ifndef _TopAbs_State_HeaderFile
#include <TopAbs_State.hxx>
#endif
#ifndef _IntCurveSurface_TransitionOnCurve_HeaderFile
#include <IntCurveSurface_TransitionOnCurve.hxx>
#endif
class BRepTopAdaptor_TopolTool;
class BRepAdaptor_HSurface;
class StdFail_NotDone;
class TopoDS_Shape;
class GeomAdaptor_Curve;
class gp_Lin;
class IntCurveSurface_IntersectionPoint;
class gp_Pnt;
class TopoDS_Face;


//! Computes the intersection between a face and a curve <br>
//! <br>
class BRepIntCurveSurface_Inter  {
public:

  void* operator new(size_t,void* anAddress) 
  {
    return anAddress;
  }
  void* operator new(size_t size) 
  {
    return Standard::Allocate(size); 
  }
  void  operator delete(void *anAddress) 
  {
    if (anAddress) Standard::Free((Standard_Address&)anAddress); 
  }

  //! Empty constructor; <br>
  Standard_EXPORT   BRepIntCurveSurface_Inter();
  //! Load the Shape, the curve  and initialize the <br>
//!           tolerance used for the classification. <br>
  Standard_EXPORT     void Init(const TopoDS_Shape& Sh,const GeomAdaptor_Curve& Cu,const Standard_Real Tol) ;
  //! Load the Shape, the curve  and initialize the <br>
//!           tolerance used for the classification. <br>
  Standard_EXPORT     void Init(const TopoDS_Shape& Sh,const gp_Lin& L,const Standard_Real Tol) ;
  //! returns True if there is a current face. <br>
  Standard_EXPORT     Standard_Boolean More() const;
  //! Sets the explorer to the next face. <br>
  Standard_EXPORT     void Next() ;
  //! returns the current Intersection point. <br>
  Standard_EXPORT     IntCurveSurface_IntersectionPoint Point() const;
  //! returns the current geometric Point <br>
  Standard_EXPORT    const gp_Pnt& Pnt() const;
  //! returns the U parameter of the current point <br>
//!          on the current face. <br>
  Standard_EXPORT     Standard_Real U() const;
  //! returns the V parameter of the current point <br>
//!          on the current face. <br>
  Standard_EXPORT     Standard_Real V() const;
  //! returns the  parameter of the current point <br>
//!          on the curve. <br>
  Standard_EXPORT     Standard_Real W() const;
  //! returns the current state  (IN or ON) <br>
  Standard_EXPORT     TopAbs_State State() const;
  //! returns the transition of the line on the surface (IN or OUT or UNKNOWN) <br>
  Standard_EXPORT     IntCurveSurface_TransitionOnCurve Transition() const;
  //! returns the current face. <br>
  Standard_EXPORT    const TopoDS_Face& Face() const;





protected:

  //! Internal function <br>
  Standard_EXPORT     void Find() ;




private:



Standard_Boolean empty;
Standard_Boolean curveisaline;
Standard_Real tolerance;
gp_Lin line;
GeomAdaptor_Curve curve;
TopExp_Explorer explorer;
BRepClass_FaceClassifier classifier;
IntCurveSurface_HInter intcs;
Standard_Integer currentindex;
Standard_Integer currentnbpoints;
Handle_BRepTopAdaptor_TopolTool FastClass;
Handle_BRepAdaptor_HSurface SurfForFastClass;
TopAbs_State currentstate;
Standard_Real currentU;
Standard_Real currentV;


};





// other Inline functions and methods (like "C++: function call" methods)


#endif