]> OCCT Git - occt.git/commitdiff
0033581: Modeling Algorithm - HLR produces wrong results or stucks on the given models
authorakaftasev <akaftasev@opencascade.com>
Mon, 22 Jan 2024 12:38:55 +0000 (12:38 +0000)
committerdpasukhi <dpasukhi@opencascade.com>
Thu, 31 Jul 2025 08:56:22 +0000 (09:56 +0100)
This reverts commit 06392edef74968449a58afd200bc49e39ca3652f.

src/ModelingAlgorithms/TKGeomAlgo/IntWalk/IntWalk_IWalking.gxx
tests/bugs/modalg_7/bug27390_1
tests/bugs/modalg_7/bug27390_2
tests/bugs/modalg_7/bug32291 [deleted file]

index 93253ca42bb4a72b93f8d7a23639b7d7690e6cb4..45657839f60cb03fcdfdc2539be6a88f9584d39e 100644 (file)
@@ -2126,8 +2126,6 @@ void IntWalk_IWalking::ComputeCloseLine(const TColStd_SequenceOfReal& Umult,
 #ifdef CHRONO
         Chronrsnld.Stop();
 #endif
-        Standard_Boolean isOnDegeneratedBorder = Standard_False;
-
         if (Cadre)
         { // update of limits.
           BornInf(1) = Um;
@@ -2220,7 +2218,6 @@ void IntWalk_IWalking::ComputeCloseLine(const TColStd_SequenceOfReal& Umult,
                       aScaleCoeff = Abs((Uvap(aCoordIdx) - uv[aCoordIdx - 1]) / (uv[aCoordIdx - 1] - uvprev[aCoordIdx - 1]));
                     Standard_Integer aFixIdx = aCoordIdx == 1 ? 2 : 1; // Fixing index;
                     Uvap(aFixIdx)            = uv[aFixIdx - 1] + (uv[aFixIdx - 1] - uvprev[aFixIdx - 1]) * aScaleCoeff;
-                    isOnDegeneratedBorder    = Standard_True;
                   }
                 }
               }
@@ -2276,17 +2273,13 @@ void IntWalk_IWalking::ComputeCloseLine(const TColStd_SequenceOfReal& Umult,
                 { // jag 941017
                   MakeWalkingPoint(2, Uvap(1), Uvap(2), Func, Psol);
                   Tgtend = Func.IsTangent(); // jag 940616
-                  if (isOnDegeneratedBorder)
-                    Tgtend = Standard_True;
-                  N = -N;
+                  N      = -N;
                 }
                 Arrive = (wd2[I].etat == 12); // the line is open
               }
             }
-            aStatus = TestDeflection(Func, Arrive, Uvap, StatusPrecedent, NbDivision, PasC, StepSign);
-
-            if (isOnDegeneratedBorder && Tgtend)
-              aStatus = IntWalk_ArretSurPoint;
+            aStatus =
+              TestDeflection(Func, Arrive, Uvap, StatusPrecedent, NbDivision, PasC, StepSign);
 
             StatusPrecedent = aStatus;
             if (aStatus == IntWalk_PasTropGrand)
index 2ec6521b9d3211ed86c3c66dd58e0000a657b2b6..0279f17348c3225c3ac61d77e82657a387e0d032 100755 (executable)
@@ -19,14 +19,14 @@ checkprops result -s 8206.54
 set nbshapes_expected "
 Number of shapes in shape
  VERTEX    : 5
- EDGE      : 8
+ EDGE      : 9
  WIRE      : 4
  FACE      : 4
  SHELL     : 1
  SOLID     : 1
  COMPSOLID : 0
  COMPOUND  : 1
- SHAPE     : 24
+ SHAPE     : 25
 "
 checknbshapes result -ref ${nbshapes_expected} -t -m "Boolean operations common"
 
index c1b41651afea0edbf9e0672ec3220bf4a3fd2373..357657c6dc7a09d46db349599896c0a4340e8895 100755 (executable)
@@ -19,14 +19,14 @@ checkprops result -s 34566
 set nbshapes_expected "
 Number of shapes in shape
  VERTEX    : 13
- EDGE      : 20
+ EDGE      : 21
  WIRE      : 8
  FACE      : 8
  SHELL     : 1
  SOLID     : 1
  COMPSOLID : 0
  COMPOUND  : 1
- SHAPE     : 52
+ SHAPE     : 53
 "
 checknbshapes result -ref ${nbshapes_expected} -t -m "Boolean operations cut"
 
diff --git a/tests/bugs/modalg_7/bug32291 b/tests/bugs/modalg_7/bug32291
deleted file mode 100644 (file)
index fb12577..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-puts "======================================================="
-puts " 0032291: General Fuse produces wrong number of solids"
-puts "======================================================="
-puts ""
-
-restore [locate_data_file bug32291.brep] s
-
-explode s
-baddobjects s_1
-baddtools s_2 s_3 s_4 s_5 s_6 s_7 s_8
-bfillds
-bbuild result
-
-checkshape result
-
-checknbshapes result -vertex 79 -edge 176 -wire 112 -face 112 -shell 18 -solid 18
-
-set tolres [checkmaxtol result]
-
-if { ${tolres} > 7.e-5} {
-   puts "Error: bad tolerance of result"
-}
-
-axo
-clear
-explode result So
-fit
-
-checkview -screenshot -2d -path ${imagedir}/${test_image}.png