0026738: Make Boolean operations safely treating arguments when running with fuzzy...
[occt.git] / src / IntTools / IntTools_Context.hxx
index d7ff8ad..03a1e23 100644 (file)
@@ -23,6 +23,7 @@
 #include <BOPCol_DataMapOfTransientAddress.hxx>
 #include <Standard_Integer.hxx>
 #include <Standard_Real.hxx>
+#include <Precision.hxx>
 #include <MMgt_TShared.hxx>
 #include <TopAbs_State.hxx>
 #include <Standard_Boolean.hxx>
@@ -111,37 +112,40 @@ Standard_EXPORT virtual  ~IntTools_Context();
   Standard_EXPORT Standard_Integer ComputePE (const gp_Pnt& theP, const Standard_Real theTolP,
                                               const TopoDS_Edge& theE, Standard_Real& theT,
                                               Standard_Real& theDist);
-  
+
 
   //! Computes parameter of the vertex aV on
-  //! the edge aE and new increased value of vertex tolerance.
+  //! the edge aE and correct tolerance value for 
+  //! the vertex on the edge.
   //! Returns zero if the distance between vertex
-  //! and edge is less than sum of tolerances,
+  //! and edge is less than sum of tolerances and the fuzzy value,
   //! otherwise and for following conditions returns
   //! negative value: <br>
   //! 1. the edge is degenerated (-1) <br>
   //! 2. the edge does not contain 3d curve and pcurves (-2) <br>
   //! 3. projection algorithm failed (-3)
-  Standard_EXPORT Standard_Integer ComputeVE (const TopoDS_Vertex& aV,
-                                              const TopoDS_Edge& aE,
-                                              Standard_Real& aParam,
-                                              Standard_Real& aTolVnew);
+  Standard_EXPORT Standard_Integer ComputeVE (const TopoDS_Vertex& theV,
+                                const TopoDS_Edge& theE, 
+                                Standard_Real& theT,
+                                Standard_Real& theTol,
+                                const Standard_Real theFuzz = Precision::Confusion());
 
 
   //! Computes UV parameters of the vertex aV on face aF
-  //! and new increased value of vertex tolerance.
+  //! and correct tolerance value for the vertex on the face.
   //! Returns zero if the distance between vertex and face is
-  //! less than or equal the sum of tolerances and the projection
-  //! point lays inside boundaries of the face.
+  //! less than or equal the sum of tolerances and the fuzzy value 
+  //! and the projection point lays inside boundaries of the face.
   //! For following conditions returns negative value <br>
   //! 1. projection algorithm failed (-1) <br>
   //! 2. distance is more than sum of tolerances (-2) <br>
   //! 3. projection point out or on the boundaries of face (-3)
-  Standard_EXPORT Standard_Integer ComputeVF (const TopoDS_Vertex& aV,
-                                              const TopoDS_Face& aF,
-                                              Standard_Real& U,
-                                              Standard_Real& V,
-                                              Standard_Real& aTolVnew);
+  Standard_EXPORT Standard_Integer ComputeVF (const TopoDS_Vertex& theVertex, 
+                                const TopoDS_Face& theFace, 
+                                Standard_Real& theU,
+                                Standard_Real& theV,
+                                Standard_Real& theTol,
+                                const Standard_Real theFuzz = Precision::Confusion());
 
 
   //! Returns the state of the point aP2D
@@ -226,7 +230,6 @@ Standard_EXPORT virtual  ~IntTools_Context();
 
 
 
-
   DEFINE_STANDARD_RTTIEXT(IntTools_Context,MMgt_TShared)
 
 protected:
@@ -251,14 +254,6 @@ private:
   //! Clears map of already cached projectors.
   Standard_EXPORT void clearCachedPOnSProjectors();
 
-
-
 };
 
-
-
-
-
-
-
 #endif // _IntTools_Context_HeaderFile