EgtExecutor 1.6t3 :

- CompoChain prende estrusione di prima curva
- aggiunte Exe e Lua GetCurveLinearConvexHullXY e CurveMinAreaRectangleXY.
This commit is contained in:
Dario Sassi
2016-08-25 15:56:36 +00:00
parent 61f65bfe2a
commit 4de59fbd33
11 changed files with 177 additions and 27 deletions
+5 -4
View File
@@ -1671,7 +1671,7 @@ MyCreateCurveCompoByChain( int nParentId, const INTVECTOR& vIds,
if ( IsNull( pCrvCompo))
return GDB_ID_NULL ;
// estrusione e spessore
Vector3d vtExtr = CalcExtrusion( pGeomDB, nParentId, nRefType) ;
Vector3d vtExtr ;
double dThick = 0 ;
// vettore con elenco Id curve originali
INTVECTOR vOrig ;
@@ -1699,7 +1699,8 @@ MyCreateCurveCompoByChain( int nParentId, const INTVECTOR& vIds,
// recupero eventuali estrusione (già nel riferimento destinazione) e spessore
Vector3d vtTemp ;
if ( pCopCrv->GetExtrusion( vtTemp)) {
vtExtr = vtTemp ;
if ( vtExtr.IsSmall())
vtExtr = vtTemp ;
double dTemp ;
if ( pCopCrv->GetThickness( dTemp) && fabs( dTemp) > fabs( dThick))
dThick = dTemp ;
@@ -1721,6 +1722,8 @@ MyCreateCurveCompoByChain( int nParentId, const INTVECTOR& vIds,
pCrvCompo->ModifyEnd( ptStart) ;
}
// imposto estrusione e spessore
if ( vtExtr.IsSmall())
vtExtr = CalcExtrusion( pGeomDB, nParentId, nRefType) ;
pCrvCompo->SetExtrusion( vtExtr) ;
pCrvCompo->SetThickness( dThick) ;
// aggiorno il nuovo punto vicino
@@ -1875,8 +1878,6 @@ ExeCreateCurveCompoByApproximation( int nParentId, const PolyLine& PL, int nType
Frame3d frDest ;
bOk = bOk && pGeomDB->GetGroupGlobFrame( nParentId, frDest) ;
// eseguo approssimazione
const double ANG_TOL_STD_DEG = 15 ;
const double LIN_FEA_STD = 20 ;
CurveByApprox crvByApprox ;
Point3d ptP ;
for ( bool bFound = PL.GetFirstPoint( ptP) ;