1 // Created on: 1992-11-18
2 // Created by: Remi LEQUETTE
3 // Copyright (c) 1992-1999 Matra Datavision
4 // Copyright (c) 1999-2014 OPEN CASCADE SAS
6 // This file is part of Open CASCADE Technology software library.
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.
14 // Alternatively, this file may be used under the terms of Open CASCADE
15 // commercial license or contractual agreement.
17 #ifndef _BRepClass_FClassifier_HeaderFile
18 #define _BRepClass_FClassifier_HeaderFile
20 #include <Standard.hxx>
21 #include <Standard_DefineAlloc.hxx>
22 #include <Standard_Handle.hxx>
24 #include <BRepClass_FClass2dOfFClassifier.hxx>
25 #include <BRepClass_Edge.hxx>
26 #include <Standard_Real.hxx>
27 #include <IntRes2d_Position.hxx>
28 #include <Standard_Boolean.hxx>
29 #include <TopAbs_State.hxx>
30 class Standard_DomainError;
31 class BRepClass_FaceExplorer;
33 class BRepClass_Intersector;
34 class BRepClass_FClass2dOfFClassifier;
39 class BRepClass_FClassifier
46 //! Empty constructor, undefined algorithm.
47 Standard_EXPORT BRepClass_FClassifier();
49 //! Creates an algorithm to classify the Point P with
50 //! Tolerance <T> on the face described by <F>.
51 Standard_EXPORT BRepClass_FClassifier(BRepClass_FaceExplorer& F, const gp_Pnt2d& P, const Standard_Real Tol);
53 //! Classify the Point P with Tolerance <T> on the
54 //! face described by <F>.
55 Standard_EXPORT void Perform (BRepClass_FaceExplorer& F, const gp_Pnt2d& P, const Standard_Real Tol);
57 //! Returns the result of the classification.
58 Standard_EXPORT TopAbs_State State() const;
60 //! Returns True when the state was computed by a
61 //! rejection. The state is OUT.
62 Standard_Boolean Rejected() const;
64 //! Returns True if the face contains no wire. The
66 Standard_Boolean NoWires() const;
68 //! Returns the Edge used to determine the
69 //! classification. When the State is ON this is the
70 //! Edge containing the point.
71 Standard_EXPORT const BRepClass_Edge& Edge() const;
73 //! Returns the parameter on Edge() used to determine the
75 Standard_EXPORT Standard_Real EdgeParameter() const;
77 //! Returns the position of the point on the edge
79 IntRes2d_Position Position() const;
88 BRepClass_FClass2dOfFClassifier myClassifier;
89 BRepClass_Edge myEdge;
90 Standard_Real myEdgeParameter;
91 IntRes2d_Position myPosition;
92 Standard_Boolean rejected;
93 Standard_Boolean nowires;
104 #define TheFaceExplorer BRepClass_FaceExplorer
105 #define TheFaceExplorer_hxx <BRepClass_FaceExplorer.hxx>
106 #define TheEdge BRepClass_Edge
107 #define TheEdge_hxx <BRepClass_Edge.hxx>
108 #define TheIntersection2d BRepClass_Intersector
109 #define TheIntersection2d_hxx <BRepClass_Intersector.hxx>
110 #define TopClass_FClass2d BRepClass_FClass2dOfFClassifier
111 #define TopClass_FClass2d_hxx <BRepClass_FClass2dOfFClassifier.hxx>
112 #define TopClass_FaceClassifier BRepClass_FClassifier
113 #define TopClass_FaceClassifier_hxx <BRepClass_FClassifier.hxx>
115 #include <TopClass_FaceClassifier.lxx>
117 #undef TheFaceExplorer
118 #undef TheFaceExplorer_hxx
121 #undef TheIntersection2d
122 #undef TheIntersection2d_hxx
123 #undef TopClass_FClass2d
124 #undef TopClass_FClass2d_hxx
125 #undef TopClass_FaceClassifier
126 #undef TopClass_FaceClassifier_hxx
131 #endif // _BRepClass_FClassifier_HeaderFile