From 7882964b268480cf63bef8a4c5a715bf578a5fef Mon Sep 17 00:00:00 2001 From: Daniele Bariletti Date: Mon, 25 Mar 2024 09:59:21 +0100 Subject: [PATCH] EgtGeomKernel : - corretto bug nella richiesta degli edge3D di una Bezier. --- SurfBezier.cpp | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/SurfBezier.cpp b/SurfBezier.cpp index c71578f..e0a3465 100644 --- a/SurfBezier.cpp +++ b/SurfBezier.cpp @@ -2818,7 +2818,9 @@ SurfBezier::GetLoops( ICRVCOMPOPOVECTOR& vCC, bool bLineOrBezier, int nEdge) con // scorro i loop che fanno intersezioni con l'edge 0 ( V=1) e le riporto sull'edge opposto for ( pair vInters0 : vmInters[0]) { // scorro le intersezioni del loop - for ( IntCrvCrvInfo inters0 : vInters0.second) { + for ( IntCrvCrvInfo inters0 : vInters0.second) { + if ( ! inters0.bOverlap) + continue ; Point3d ptStart0 = inters0.IciA[0].ptI ; Point3d ptEnd0 = inters0.IciA[1].ptI ; // porto i punti sull'edge opposto @@ -2880,7 +2882,7 @@ SurfBezier::GetLoops( ICRVCOMPOPOVECTOR& vCC, bool bLineOrBezier, int nEdge) con ptOverlapS.y = m_nSpanV * SBZ_TREG_COEFF ; ptOverlapE.y = m_nSpanV * SBZ_TREG_COEFF ; double dStart0, dEnd0 ; - // scorro tutte le curve in cui è stato splittato il loop iniziale + // scorro tutte le curve in cui è stato splittato il loop corrente for ( int j = 0 ; j < int( mSplitLoop[vInters0.first].size()) ; ++j ) { int nIndex0 = mSplitLoop[vInters0.first][j] ; if ( ! m_vCCLoop[nIndex0]->GetParamAtPoint( ptOverlapS, dStart0) || ! m_vCCLoop[nIndex0]->GetParamAtPoint( ptOverlapE, dEnd0)) @@ -2906,9 +2908,9 @@ SurfBezier::GetLoops( ICRVCOMPOPOVECTOR& vCC, bool bLineOrBezier, int nEdge) con else if ( bDoneB) m_vCCLoop[nIndex0].Set( pCC0b) ; } - break ; + //break ; } - break ; + //break ; } } } @@ -2922,6 +2924,8 @@ SurfBezier::GetLoops( ICRVCOMPOPOVECTOR& vCC, bool bLineOrBezier, int nEdge) con for ( pair vInters1 : vmInters[1]) { // scorro le intersezioni del loop for ( IntCrvCrvInfo inters1 : vInters1.second) { + if ( ! inters1.bOverlap) + continue ; Point3d ptStart1 = inters1.IciA[0].ptI ; Point3d ptEnd1 = inters1.IciA[1].ptI ; // porto i punti sull'edge opposto @@ -3009,9 +3013,9 @@ SurfBezier::GetLoops( ICRVCOMPOPOVECTOR& vCC, bool bLineOrBezier, int nEdge) con else if ( bDoneB) m_vCCLoop[nIndex1].Set( pCC1b) ; } - break ; + //break ; } - break ; + //break ; } } }