OCC22322 Improvement extrema Additional integration
[occt.git] / src / BRepExtrema / BRepExtrema_ExtFF.hxx
CommitLineData
92d1589b
A
1// This file is generated by WOK (CPPExt).
2// Please do not edit this file; modify original file instead.
3// The copyright and license terms as defined for the original file apply to
4// this header file considered to be the "object code" form of the original source.
5
6#ifndef _BRepExtrema_ExtFF_HeaderFile
7#define _BRepExtrema_ExtFF_HeaderFile
8
9#ifndef _Standard_HeaderFile
10#include <Standard.hxx>
11#endif
12#ifndef _Standard_Macro_HeaderFile
13#include <Standard_Macro.hxx>
14#endif
15
16#ifndef _Extrema_ExtSS_HeaderFile
17#include <Extrema_ExtSS.hxx>
18#endif
19#ifndef _Standard_Integer_HeaderFile
20#include <Standard_Integer.hxx>
21#endif
22#ifndef _TColStd_SequenceOfReal_HeaderFile
23#include <TColStd_SequenceOfReal.hxx>
24#endif
25#ifndef _Extrema_SequenceOfPOnSurf_HeaderFile
26#include <Extrema_SequenceOfPOnSurf.hxx>
27#endif
28#ifndef _Handle_BRepAdaptor_HSurface_HeaderFile
29#include <Handle_BRepAdaptor_HSurface.hxx>
30#endif
31#ifndef _Standard_Boolean_HeaderFile
32#include <Standard_Boolean.hxx>
33#endif
34#ifndef _Standard_Real_HeaderFile
35#include <Standard_Real.hxx>
36#endif
37#ifndef _Extrema_POnSurf_HeaderFile
38#include <Extrema_POnSurf.hxx>
39#endif
40class BRepAdaptor_HSurface;
41class TopoDS_Face;
42class gp_Pnt;
43
44
45
46class BRepExtrema_ExtFF
47{
48 public:
49
50 void* operator new(size_t,void* anAddress)
51 {
52 return anAddress;
53 }
54 void* operator new(size_t size)
55 {
56 return Standard::Allocate(size);
57 }
58 void operator delete(void *anAddress)
59 {
60 if (anAddress) Standard::Free((Standard_Address&)anAddress);
61 }
62
63
64 Standard_EXPORT BRepExtrema_ExtFF()
65 {
66 }
67 //! It calculates all the distances. <br>
68 Standard_EXPORT BRepExtrema_ExtFF(const TopoDS_Face& F1,const TopoDS_Face& F2);
69
70 Standard_EXPORT void Initialize(const TopoDS_Face& F2) ;
71 //! An exception is raised if the fields have not been initialized. <br>
72 //! Be careful: this method uses the Face F2 only for classify, not for the fields. <br>
73 Standard_EXPORT void Perform(const TopoDS_Face& F1,const TopoDS_Face& F2);
74 //! True if the distances are found. <br>
75 Standard_EXPORT Standard_Boolean IsDone() const
76 {
77 return myExtSS.IsDone();
78 }
79 //! Returns True if the surfaces are parallel. <br>
80 Standard_EXPORT Standard_Boolean IsParallel() const
81 {
82 return myExtSS.IsParallel();
83 }
84 //! Returns the number of extremum distances. <br>
85 Standard_EXPORT Standard_Integer NbExt() const
86 {
87 return mySqDist.Length();
88 }
89 //! Returns the value of the <N>th extremum square distance. <br>
90 Standard_EXPORT Standard_Real SquareDistance(const Standard_Integer N) const
91 {
92 return mySqDist.Value(N);
93 }
94 //! Returns the parameters on the Face F1 of the <N>th extremum distance. <br>
95 Standard_EXPORT void ParameterOnFace1(const Standard_Integer N,Standard_Real& U,Standard_Real& V) const
96 {
97 myPointsOnS1.Value(N).Parameter(U, V);
98 }
99 //! Returns the parameters on the Face F2 of the <N>th extremum distance. <br>
100 Standard_EXPORT void ParameterOnFace2(const Standard_Integer N,Standard_Real& U,Standard_Real& V) const
101 {
102 myPointsOnS2.Value(N).Parameter(U, V);
103 }
104 //! Returns the Point of the <N>th extremum distance. <br>
105 Standard_EXPORT gp_Pnt PointOnFace1(const Standard_Integer N) const
106 {
107 return myPointsOnS1.Value(N).Value();
108 }
109 //! Returns the Point of the <N>th extremum distance. <br>
110 Standard_EXPORT gp_Pnt PointOnFace2(const Standard_Integer N) const
111 {
112 return myPointsOnS2.Value(N).Value();
113 }
114
115 private:
116
117 Extrema_ExtSS myExtSS;
118 TColStd_SequenceOfReal mySqDist;
119 Extrema_SequenceOfPOnSurf myPointsOnS1;
120 Extrema_SequenceOfPOnSurf myPointsOnS2;
121 Handle_BRepAdaptor_HSurface myHS;
122};
123
124#endif