]> SALOME platform Git repositories - tools/medcoupling.git/commitdiff
Salome HOME
Use adimensional principal curvatures to find types of the nodes
authorEl Hadi Moussi <moussi@phimeca.com>
Wed, 7 Aug 2024 07:56:17 +0000 (09:56 +0200)
committerEl Hadi Moussi <moussi@phimeca.com>
Wed, 7 Aug 2024 07:56:17 +0000 (09:56 +0200)
src/ShapeRecogn/NodeCurvatureCalculator.cxx

index 7b796aa541224c0462fc221f209e46a89a3273b1..7787240862a0dbaa652035179c9e021c8a7cae57 100644 (file)
@@ -144,7 +144,8 @@ void NodeCurvatureCalculator::computeCurvatures(mcIdType nodeId, double tol)
             mainDirection = direction2;
             weakDirection = direction1;
         }
-        primitive = findPrimitiveType(k1, k2, kdiff0, kis0);
+        double averageDistance = computeAverageDistance(nodeId, neighborIds);
+        primitive = findPrimitiveType(k1 * averageDistance, k2 * averageDistance, kdiff0 * averageDistance, kis0 * averageDistance);
     }
     // Populate nodes
     nodes->isConvex[nodeId] = isConvex;