EgtMachKernel :

- ApproxWithArcsIfUseful in milling e pocketing solo se curve piane o quasi.
This commit is contained in:
Dario Sassi
2018-05-23 13:29:17 +00:00
parent 71ef4e79a1
commit ad5c015b46
+6
View File
@@ -643,6 +643,12 @@ Operation::ApproxWithArcsIfUseful( ICurveComposite* pCompo)
int nCrvs = pCompo->GetCurveCount() ;
if ( nCrvs < 5 || dLen > nCrvs * LIN_FEA_STD)
return true ;
// limito l'approssimazione alle curve piane
Frame3d frRef ;
frRef.Set( ORIG, vtExtr) ;
BBox3d b3Crv ;
if ( ! pCompo->GetBBox( frRef, b3Crv) || ! b3Crv.IsEpsilonZ( 100 * EPS_SMALL))
return true ;
// calcolo approssimazione con archi (se possibile)
PolyArc PA ;
if ( ! pCompo->ApproxWithArcsEx( LIN_TOL_MID, ANG_TOL_STD_DEG, LIN_FEA_STD, PA))