EgtMachKernel 1.8d1 :
- aggiunti a fresature attacchi e uscite ad inseguimento - corretti problemi con verifica collisioni - corretti problemi con caricamento utensili su testa con TC.
This commit is contained in:
+6
-18
@@ -23,6 +23,7 @@
|
||||
#include "/EgtDev/Include/EGkArcSpecial.h"
|
||||
#include "/EgtDev/Include/EGkChainCurves.h"
|
||||
#include "/EgtDev/Include/EGkOffsetCurve.h"
|
||||
#include "/EgtDev/Include/EGkCurveAux.h"
|
||||
#include "/EgtDev/Include/EGkSfrCreate.h"
|
||||
#include "/EgtDev/Include/EGkSurfTriMesh.h"
|
||||
#include "/EgtDev/Include/EGkUserObjFactory.h"
|
||||
@@ -2061,34 +2062,21 @@ Pocketing::AddLeadIn( const Point3d& ptP1, const Point3d& ptStart, const Vector3
|
||||
if ( ! pCrv.Set( pRCrv->Clone()))
|
||||
return false ;
|
||||
}
|
||||
pCrv->SetExtrusion( vtN) ;
|
||||
// la porto alla giusta quota
|
||||
Point3d ptFin ; pCrv->GetEndPoint( ptFin) ;
|
||||
Vector3d vtMove = ptStart - ptFin ;
|
||||
pCrv->Translate( vtMove) ;
|
||||
// sposto il punto iniziale e rendo uniforme la pendenza
|
||||
double dDeltaN = ( ptP1 - ptStart) * vtN ;
|
||||
int i = 0 ;
|
||||
double dCurrLen = 0 ;
|
||||
const ICurve* pSCrv = pCrv->GetFirstCurve() ;
|
||||
while ( pSCrv != nullptr) {
|
||||
double dCrvLen ;
|
||||
pSCrv->GetLength( dCrvLen) ;
|
||||
double dCurrDeltaN = dDeltaN * ( 1.0 - dCurrLen / dLen) ;
|
||||
Point3d ptJoin ;
|
||||
pSCrv->GetStartPoint( ptJoin) ;
|
||||
pCrv->ModifyJoint( i, ptJoin + vtN * dCurrDeltaN) ;
|
||||
// passo al successivo
|
||||
dCurrLen += dCrvLen ;
|
||||
pSCrv = pCrv->GetNextCurve() ;
|
||||
++ i ;
|
||||
}
|
||||
// assegno la corretta pendenza
|
||||
double dNini = ( ptP1 - ORIG) * vtN ;
|
||||
double dNfin = ( ptStart - ORIG) * vtN ;
|
||||
AdjustCurveSlope( pCrv, dNini, dNfin) ;
|
||||
// eventuale spezzatura
|
||||
if ( bSplitArcs && ! ApproxWithLines( pCrv))
|
||||
return false ;
|
||||
// emetto
|
||||
return ( AddCurveMove( pCrv) != GDB_ID_NULL) ;
|
||||
}
|
||||
return false ;
|
||||
case POCKET_LI_ZIGZAG :
|
||||
{
|
||||
double dDeltaN = ( ptStart - ptP1) * vtN ;
|
||||
|
||||
Reference in New Issue
Block a user