mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0023404: Create SquareConfusion function in Precision package for speed and convenience
SquareConfusion function was created in FoundationClasses module -> TKMath toolkit -> Precision package. The function returns square of Precision::Confusion(). SquareConfusion function was corrected in FoundationClasses module -> TKMath toolkit -> Precision package. Squares of Precision::Confusion() were replaced by Precision::SquareConfusion().
This commit is contained in:
@@ -980,7 +980,7 @@ Standard_Boolean ShapeAnalysis_Curve::IsPlanar (const TColgp_Array1OfPnt& pnts,
|
||||
return Standard_True;
|
||||
}
|
||||
gp_XYZ aVecMul = N1^Normal;
|
||||
return aVecMul.SquareModulus() < Precision::Confusion()*Precision::Confusion();
|
||||
return aVecMul.SquareModulus() < Precision::SquareConfusion();
|
||||
}
|
||||
|
||||
if (curve->IsKind(STANDARD_TYPE(Geom_TrimmedCurve))) {
|
||||
|
@@ -228,7 +228,7 @@ void ShapeAnalysis_WireOrder::Perform(const Standard_Boolean /*closed*/)
|
||||
fins(i) = myXYZ->Value(2*i);
|
||||
}
|
||||
|
||||
Standard_Real tol2 = Precision::Confusion()*Precision::Confusion();
|
||||
Standard_Real tol2 = Precision::SquareConfusion();
|
||||
idone(1) = Standard_True;
|
||||
gp_Pnt wireFirst = debs(1);
|
||||
gp_Pnt wireLast = fins(1);
|
||||
|
Reference in New Issue
Block a user