EgtMachKernel :
- in mortasatura sistemato calcolo affondamento quando inclinata rispetto al movimento - corretto calcolo spessore da associare a curva derivata da contorno superficie con TOOL_PAR_SLANT.
This commit is contained in:
@@ -1267,6 +1267,11 @@ Mortising::ProcessPath( int nPathId, int nPvId, int nClId)
|
||||
dDepth -= dThick ;
|
||||
// sottraggo eventuale offset longitudinale
|
||||
dDepth -= GetOffsL() ;
|
||||
// sottraggo eventuale ingombro di larghezza se inclinato rispetto al movimento
|
||||
Vector3d vtTg ; pCompo->GetMidDir( vtTg) ;
|
||||
double dSinAng = max( ( vtTg ^ vtExtr).Len(), sin( 30 * DEGTORAD)) ;
|
||||
double dCosAng = min( ( vtTg * vtExtr), cos( 30 * DEGTORAD)) ;
|
||||
dDepth -= m_TParams.m_dDiam / 2 * dCosAng / dSinAng ;
|
||||
|
||||
// recupero nome del path
|
||||
string sPathName ;
|
||||
|
||||
+10
-2
@@ -876,8 +876,16 @@ Operation::AdjustCurveFromSurf( ICurveComposite* pCrvCompo, int nToolDir, int nF
|
||||
frExtr.Set( ORIG, vtExtr) ;
|
||||
frExtr.Invert() ;
|
||||
BBox3d b3Extr ; pCopy->GetBBox( frExtr, b3Extr) ;
|
||||
if ( ! b3Extr.IsEmpty())
|
||||
pCrvCompo->SetThickness( b3Extr.GetMax().z - b3Extr.GetMin().z) ;
|
||||
if ( ! b3Extr.IsEmpty()) {
|
||||
double dThick = b3Extr.GetMax().z - b3Extr.GetMin().z ;
|
||||
Point3d ptStart, ptEnd ;
|
||||
if ( nToolDir == TOOL_PAR_SLANT && pCrvCompo->IsALine( LIN_TOL_STD, ptStart, ptEnd)) {
|
||||
BBox3d b3Crv ; pCrvCompo->GetBBox( frExtr, b3Crv) ;
|
||||
if ( ! b3Crv.IsEmpty())
|
||||
dThick -= b3Crv.GetMax().z - b3Crv.GetMin().z ;
|
||||
}
|
||||
pCrvCompo->SetThickness( dThick) ;
|
||||
}
|
||||
}
|
||||
}
|
||||
return true ;
|
||||
|
||||
Reference in New Issue
Block a user