EgtMachKernel :
- riportate correzioni a SurfRoughing di RiccardoE - ulterirori modifiche per NewLinkMgr.
This commit is contained in:
+6
-4
@@ -2959,6 +2959,9 @@ Operation::ManageProtectedAreas( const DBLVECTOR& vAxStart, const DBLVECTOR& vAx
|
||||
// recupero flag nuova gestione collegamenti tra lavorazioni
|
||||
bool bNewLink = m_pMchMgr->GetCurrMachine()->GetNewLinkMgr() ;
|
||||
|
||||
// codifica tipo di collegamento
|
||||
int nLinkType = 0 + ( pPrevOp == nullptr ? 0 : 2) + ( pNextOp == nullptr ? 0 : 1) ;
|
||||
|
||||
// Verifico se il collegamento le attraversa
|
||||
Point3d ptSta( vAxStart[0], vAxStart[1], vAxStart[2]) ;
|
||||
Point3d ptEnd( vAxEnd[0], vAxEnd[1], vAxEnd[2]) ;
|
||||
@@ -2971,10 +2974,10 @@ Operation::ManageProtectedAreas( const DBLVECTOR& vAxStart, const DBLVECTOR& vAx
|
||||
// verifico inizio e fine
|
||||
int nOutstroke = 0 ;
|
||||
int nStSta = 0 ;
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptSta.x, ptSta.y, ptSta.z, vAngSta, true, nStSta) || nStSta != 0)
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptSta.x, ptSta.y, ptSta.z, vAngSta, nLinkType, nStSta) || nStSta != 0)
|
||||
nOutstroke |= 2 ;
|
||||
int nStEnd = 0 ;
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptEnd.x, ptEnd.y, ptEnd.z, vAngEnd, true, nStEnd) || nStEnd != 0)
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptEnd.x, ptEnd.y, ptEnd.z, vAngEnd, nLinkType, nStEnd) || nStEnd != 0)
|
||||
nOutstroke |= 1 ;
|
||||
// verifico i punti intermedi
|
||||
const double PA_VERIF_LEN = 10 ;
|
||||
@@ -2987,7 +2990,7 @@ Operation::ManageProtectedAreas( const DBLVECTOR& vAxStart, const DBLVECTOR& vAx
|
||||
for ( int j = 0 ; j < int( vAngSta.size()) ; ++ j)
|
||||
vAng.emplace_back( ( 1 - dCoeff) * vAngSta[j] + dCoeff * vAngEnd[j]) ;
|
||||
int nStat = 0 ;
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptCurr.x, ptCurr.y, ptCurr.z, vAng, true, nStat) || nStat != 0)
|
||||
if ( ! m_pMchMgr->GetCurrMachine()->VerifyProtectedAreas( ptCurr.x, ptCurr.y, ptCurr.z, vAng, nLinkType, nStat) || nStat != 0)
|
||||
nOutstroke |= 4 ;
|
||||
}
|
||||
if ( nOutstroke == 0)
|
||||
@@ -3008,7 +3011,6 @@ Operation::ManageProtectedAreas( const DBLVECTOR& vAxStart, const DBLVECTOR& vAx
|
||||
return false ;
|
||||
|
||||
// chiamo funzione script OnSpecialRapidMove per avere posizioni di movimento
|
||||
int nLinkType = 0 + ( pPrevOp == nullptr ? 0 : 2) + ( pNextOp == nullptr ? 0 : 1) ;
|
||||
POSVECTOR vPosNew ;
|
||||
bool bOk = SpecialMoveRapid( vNeatAxSta, vNeatAxEnd, nOutstroke, nLinkType, vPosNew) ;
|
||||
// se tutto bene, eseguo cancellazioni e inserimenti come richiesto
|
||||
|
||||
Reference in New Issue
Block a user