EgtMachKernel :
- correzione risalite sui link tra lavorazioni.
This commit is contained in:
+12
-4
@@ -1704,7 +1704,7 @@ Operation::AdjustStartEndMovements( bool bVerifyPreviousLink)
|
||||
while ( bOk && nClPathId != GDB_ID_NULL) {
|
||||
// se richiesta verifica collegamento con lavorazione precedente, sistemo inizio
|
||||
if ( bVerifyPreviousLink) {
|
||||
if ( ! AdjustOneStartMovement( nClPathId, nPrevClPathId, vAxVal, bMaxZ))
|
||||
if ( ! AdjustOneStartMovement( nClPathId, nPrevClPathId, pPrevOp, vAxVal, bMaxZ))
|
||||
bOk = false ;
|
||||
}
|
||||
bMaxZ = false ;
|
||||
@@ -1731,7 +1731,7 @@ Operation::AdjustStartEndMovements( bool bVerifyPreviousLink)
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
Operation::AdjustOneStartMovement( int nClPathId, int nPrevClPathId, const DBLVECTOR& vAxPrev, bool bMaxZ)
|
||||
Operation::AdjustOneStartMovement( int nClPathId, int nPrevClPathId, Operation* pPrevOp, const DBLVECTOR& vAxPrev, bool bMaxZ)
|
||||
{
|
||||
if ( m_pMchMgr == nullptr || m_pGeomDB == nullptr)
|
||||
return false ;
|
||||
@@ -1798,8 +1798,16 @@ Operation::AdjustOneStartMovement( int nClPathId, int nPrevClPathId, const DBLVE
|
||||
}
|
||||
// risalita sopra fine percorso precedente
|
||||
DBLVECTOR vAxNew1 ;
|
||||
if ( ! AddRise( vAxNew1, dSafeZ - vAxPrev[2], nPrevClPathId))
|
||||
return false ;
|
||||
if ( nPrevClPathId == GDB_ID_NULL) {
|
||||
if ( pPrevOp == nullptr ||
|
||||
! pPrevOp->RemoveRise() ||
|
||||
! pPrevOp->AddRise( vAxNew1, dSafeZ - vAxPrev[2]))
|
||||
return false ;
|
||||
}
|
||||
else {
|
||||
if ( ! AddRise( vAxNew1, dSafeZ - vAxPrev[2], nPrevClPathId))
|
||||
return false ;
|
||||
}
|
||||
// aggiungo posizione elevata prima dell'inizio del percorso corrente
|
||||
if ( m_pGeomDB->Copy( nEntId, GDB_ID_NULL, nEntId, GDB_AFTER) == GDB_ID_NULL)
|
||||
return false ;
|
||||
|
||||
Reference in New Issue
Block a user