]> OCCT Git - occt-copy.git/commitdiff
0031616: Modeling algorithm - Section between two shells returns wire with gaps ...
authorifv <ifv@opencascade.com>
Tue, 23 Jun 2020 10:55:15 +0000 (13:55 +0300)
committerkgv <kgv@opencascade.com>
Wed, 15 Jul 2020 13:09:41 +0000 (16:09 +0300)
src/IntTools/IntTools_TopolTool.cxx

index 863e0687fcb4894efb77e1cde8aa1e4347b11783..a6bf5c1a4aceb348a0a3a1712a7780c8de5520fa 100644 (file)
@@ -246,7 +246,22 @@ void IntTools_TopolTool::ComputeSamplePoints()
     }
     if(nbsu < 10) nbsu = 10;
     if(nbsv < 10) nbsv = 10;
+    // Check anisotropy
+    Standard_Real anULen = (usup - uinf) / myS->UResolution(1.);
+    Standard_Real anVLen = (vsup - vinf) / myS->VResolution(1.);
+    Standard_Real aRatio = anULen / anVLen;
+    if (aRatio >= 10.)
+    {
+      nbsu *= 2;
+      nbsu = Min(nbsu, aMaxNbSample);
+    }
+    else if (aRatio <= 0.1)
+    {
+      nbsv *= 2;
+      nbsv = Min(nbsv, aMaxNbSample);
+    }
   }
+  
     break;
   case GeomAbs_SurfaceOfExtrusion: {
     nbsu = 15;