EgtGeomKernel 2.4f1 :

- in accodamento curva a composita con aggiustamento estremo si verifica di non modificare troppo la curva stessa
- in offset curve migliorata gestione concatenamento finale.
This commit is contained in:
DarioS
2022-06-06 07:01:57 +02:00
parent fe0a6ad15d
commit 498e5b37f4
3 changed files with 17 additions and 8 deletions
+7
View File
@@ -209,8 +209,15 @@ CurveComposite::AddSimpleCurve( ICurve* pSmplCrv, bool bEndOrStart, double dLinT
if ( ! AreSamePointEpsilon( ptCrvStart, ptEnd, 0.01 * EPS_SMALL)) {
// se in tolleranza, modifico l'inizio dell'entità
if ( SqDist( ptCrvStart, ptEnd) < ( dLinTol * dLinTol)) {
// lunghezza della curva originale
double dOldLen ; pCrv->GetLength( dOldLen) ;
// eseguo modifica
if ( ! pCrv->ModifyStart( ptEnd))
return false ;
// verifico che la lunghezza non sia variata troppo
double dNewLen ; pCrv->GetLength( dNewLen) ;
if ( abs( dNewLen - dOldLen) > 10 * dLinTol)
return false ;
}
else
return false ;
BIN
View File
Binary file not shown.
+10 -8
View File
@@ -589,16 +589,18 @@ OffsetCurve::Make( const ICurve* pCrv, double dDist, int nType)
pCrvCo2->GetEndPoint( ptEnd2) ;
// verifiche di concatenamento
if ( AreSamePointEpsilon( ptEnd, ptStart2, 10 * EPS_SMALL)) {
pCrvCo->AddCurve( pCrvCo2, true, 10 * EPS_SMALL) ;
m_CrvLst.erase( iIter2) ;
ptEnd = ptEnd2 ;
iIter2 = next( iIter) ;
if ( pCrvCo->AddCurve( pCrvCo2, true, 10 * EPS_SMALL)) {
m_CrvLst.erase( iIter2) ;
ptEnd = ptEnd2 ;
iIter2 = next( iIter) ;
}
}
else if ( AreSamePointEpsilon( ptEnd2, ptStart, 10 * EPS_SMALL)) {
pCrvCo->AddCurve( pCrvCo2, false, 10 * EPS_SMALL) ;
m_CrvLst.erase( iIter2) ;
ptStart = ptStart2 ;
iIter2 = next( iIter) ;
if ( pCrvCo->AddCurve( pCrvCo2, false, 10 * EPS_SMALL)) {
m_CrvLst.erase( iIter2) ;
ptStart = ptStart2 ;
iIter2 = next( iIter) ;
}
}
else
++ iIter2 ;