EgtGeomKernel 2.4k5 :

- correzione in creazione regioni, eliminando curve chiude con diametro di ingombro inferiore a 20 epsilon.
This commit is contained in:
DarioS
2022-11-24 09:29:58 +01:00
parent 7c3b3e516a
commit a4bd5a25c2
3 changed files with 17 additions and 2 deletions
+16
View File
@@ -242,6 +242,22 @@ MyAdjustLoops( ICurve* pCurve, ICURVEPLIST& CrvLst)
++ iIter ;
}
// elimino le curve troppo piccole
for ( auto iIter = CrvLst.begin() ; iIter != CrvLst.end() ;) {
CurveComposite* pCrvCo = GetBasicCurveComposite( *iIter) ;
BBox3d b3CrvCo ;
double dDiam ;
if ( ! pCrvCo->GetLocalBBox( b3CrvCo) || b3CrvCo.IsEmpty() ||
! b3CrvCo.GetDiameter( dDiam) || dDiam < 20 * EPS_SMALL) {
delete pCrvCo ;
pCrvCo = nullptr ;
iIter = CrvLst.erase( iIter) ;
}
else {
++ iIter ;
}
}
// riporto le curve nel riferimento originale
if ( bNeedRef) {
for ( auto pCrv : CrvLst)