Merge commit 'b33463117ff279203a0e9e1d3aff1578a05e3d58'
This commit is contained in:
+14
-3
@@ -1710,9 +1710,20 @@ SurfRoughing::ProcessPath( int nPathId, int nPvId, int nClId)
|
||||
return false ;
|
||||
}
|
||||
if ( ! IsNull( pSfrSil) && ! it->bPlaneZStep) {
|
||||
pSfrSil->Offset( GetOffsR(), ICurve::OFF_CHAMFER) ; // offset radiale sulla Silhouette
|
||||
// provo prima con un Offset Chamfer, se non funziona provo con il Fillet ( pezza da sistemare ! )
|
||||
PtrOwner<ISurfFlatRegion> pSfrSilCheck( pSfrSil->CreateOffsetSurf( GetOffsR(), ICurve::OFF_CHAMFER)) ;
|
||||
if ( IsNull( pSfrSilCheck) || ! pSfrSilCheck->IsValid()) {
|
||||
m_pMchMgr->SetLastError( 3024, "Error in SurfRoughing : region not computable") ;
|
||||
return false ;
|
||||
}
|
||||
pSfrSil_Hypothetical.Set( CloneSurfFlatRegion( pSfrSil)) ; // regione di silhouette ipotetica
|
||||
pSfr->Subtract( *pSfrSil) ; // sottraggo le parti da non lavorare
|
||||
// sottraggo le parti da non lavorare
|
||||
if ( ! pSfr->Subtract( *pSfrSilCheck)) {
|
||||
// se non riesco, provo con un Offset di tipo Fillet
|
||||
pSfrSil->Offset( GetOffsR(), ICurve::OFF_FILLET) ;
|
||||
if ( ! pSfr->Subtract( *pSfrSil))
|
||||
return false ;
|
||||
}
|
||||
}
|
||||
if ( ! pSfr->IsValid() || pSfr->GetChunkCount() == 0) // se superficie non valida
|
||||
continue ; // passo allo step successivo ( la silhouette coincide con il grezzo )
|
||||
@@ -3181,7 +3192,7 @@ SurfRoughing::RemoveChunksUnderTolerance( ISurfFlatRegion* pSfr, double dTol,
|
||||
// rimuovo il Chunk c-esimo se l'Offset massimo è minore della tolleranza
|
||||
if ( dMaxOffs < dTol) {
|
||||
// devo evitare di rimuovere le isole aperte (queste, se rimosse, lasciano delle
|
||||
// punte di materiale che non vengono rimossein quanto sempre scartate)
|
||||
// punte di materiale che non vengono rimosse in quanto sempre scartate)
|
||||
// piccolo Offset alla regione limite
|
||||
double dOffs = m_TParams.m_dDiam / 2. + GetOffsR() + 30 * EPS_SMALL ;
|
||||
PtrOwner<ISurfFlatRegion> pSfrLimitOffs( pSfrLimit->CreateOffsetSurf( dOffs, ICurve::OFF_FILLET)) ;
|
||||
|
||||
Reference in New Issue
Block a user