]> OCCT Git - occt.git/commitdiff
0028183: Modeling - BRepExtrema_DistShapeShape does not find all solutions
authormsv <msv@opencascade.com>
Wed, 14 Dec 2016 07:09:38 +0000 (10:09 +0300)
committerapn <apn@opencascade.com>
Thu, 22 Dec 2016 09:37:54 +0000 (12:37 +0300)
Disable SetSingleSolutionFlag when calling algorithm of curve-curve Extrema.
Now DistShapeShape will find all solutions, even if they are located on the same pair of edges.
The fix brings the speed down for the cases of coinciding curves.

src/BRepExtrema/BRepExtrema_ExtCC.cxx
tests/bugs/moddata_3/bug28183

index e66a0674318fbfa4dc7f829eefac5ecc3382660d..d6fdb930773268befc25223b9f4a26369eeabfcd 100644 (file)
@@ -69,7 +69,9 @@ void BRepExtrema_ExtCC::Perform(const TopoDS_Edge& E1)
   BRep_Tool::Range(E1,U1,U2);
   myExtCC.SetCurve (1, HC->Curve(), U1, U2);
   myExtCC.SetTolerance(1, Tol);
-  myExtCC.SetSingleSolutionFlag(Standard_True);
+  // If we enable SetSingleSolutionFlag Extrema will run much quicker on almost parallel curves
+  // (e.g. bug 27665), however some solutions will be lost, e.g. see bug 28183.
+  //myExtCC.SetSingleSolutionFlag(Standard_True);
   myExtCC.Perform();
 }
 
index 5b52bc8579f72dbd86770d4f12b9de29fadee1f9..ecaace3f4b8a35e3b9a263d18eef0f3b5b166976 100644 (file)
@@ -6,8 +6,6 @@ puts ""
 # BRepExtrema_DistShapeShape does not find all solutions
 ###############################################################################
 
-puts "TODO #28183 ALL: Error: .* solutions expected"
-
 pload MODELING
 
 restore [locate_data_file bug28175_borders2.brep] b