From: emv Date: Fri, 22 Jul 2016 07:09:22 +0000 (+0300) Subject: Decreasing the maximal value for enlarging surfaces to 1.e+7 to avoid inaccuracies... X-Git-Url: http://git.dev.opencascade.org/gitweb/?a=commitdiff_plain;h=8c536e19b226a6a5bb2dc35a23a20c1ce6382d2b;p=occt-copy.git Decreasing the maximal value for enlarging surfaces to 1.e+7 to avoid inaccuracies caused by floating point format. --- diff --git a/src/BRepOffset/BRepOffset_Tool.cxx b/src/BRepOffset/BRepOffset_Tool.cxx index 66c80a0467..fd20ac5ff4 100644 --- a/src/BRepOffset/BRepOffset_Tool.cxx +++ b/src/BRepOffset/BRepOffset_Tool.cxx @@ -3220,7 +3220,16 @@ Standard_Boolean BRepOffset_Tool::EnLargeFace Standard_Boolean isVV1degen = Standard_False, isVV2degen = Standard_False; Standard_Real US1,VS1,US2,VS2; Standard_Real UF1,VF1,UF2,VF2; - Standard_Real infini = 1.e8; + // The maximal value to enlarge surfaces is decreased to 1.e+7. + // It is justified by the floating point format. As we can have only 15 + // valuable decimal numbers, then during intersection of surfaces with + // bounds of 1.e+8 the possible inaccuracy might appear already in seventh + // decimal place which will be more than Precision::Confusion value - + // 1.e-7, default tolerance value for the section curves. + // By decreasing the max enlarge value to 1.e+7 the inaccuracy will be + // shifted to eighth decimal place, i.e. the inaccuracy will be + // decreased to values less than 1.e-7. + Standard_Real infini = 1.e7;//1.e8; Standard_Boolean SurfaceChange = Standard_False; if (S->IsUPeriodic() || S->IsVPeriodic()) {