From 86395eb2d19de8a72aebd2af3a40479a09e218ce Mon Sep 17 00:00:00 2001 From: Daniele Bariletti Date: Tue, 30 Jan 2024 16:24:37 +0100 Subject: [PATCH] EgtGeomKernel : - correzione minore. --- Tree.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tree.cpp b/Tree.cpp index 1771f7c..dbc8ec0 100644 --- a/Tree.cpp +++ b/Tree.cpp @@ -1717,13 +1717,13 @@ Tree::FindCell( const Point3d& ptToAssign, const CurveLine& cl, INTVECTOR vCells ptIntersPlus = ptIntersPlus + vtDirDX * EPS_SMALL ; } else if ( (nEdge == 0 || nEdge == 2) && abs(vtDir.y) > EPS_SMALL) - ptIntersPlus.y += Sign( vtDir.y) * EPS_SMALL ; + ptIntersPlus.y += (vtDir.y > 0 ? 1 : -1) * EPS_SMALL ; else if ( ( nEdge == 1 || nEdge == 3 ) && abs(vtDir.y) > 1 - EPS_SMALL ) { Vector3d vtDirDX = vtDir ; vtDirDX.Rotate( Z_AX, -90) ; ptIntersPlus = ptIntersPlus + vtDirDX * EPS_SMALL ; } else if ( (nEdge == 1 || nEdge == 3) && abs(vtDir.x) > EPS_SMALL) - ptIntersPlus.x += Sign( vtDir.x) * EPS_SMALL ; + ptIntersPlus.x += (vtDir.x > 0 ? 1 : -1) * EPS_SMALL ; } // o in un vertice else if ( nEdge == 4 || nEdge == 5 || nEdge == 6 || nEdge == 7) {