EgtExecutor :
- allineati nomi EXE con nomi Lua (CurveLine->Line, CurveArc->Arc e ExtText->Text) - aggiunte ModifyArcToExplementary e ModifyArcByFlip a EXE e Lua - aggiunte ArcAngCenter e ArcDeltaN a EXE e Lua.
This commit is contained in:
+34
-5
@@ -671,7 +671,7 @@ ExeSplitCurveAtSelfInters( int nId, int* pnCount)
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyCurveCircleCPN( int nId, const Point3d& ptOn, int nRefType)
|
||||
ExeModifyCircleCP( int nId, const Point3d& ptOn, int nRefType)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
@@ -702,7 +702,7 @@ ExeModifyCurveCircleCPN( int nId, const Point3d& ptOn, int nRefType)
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyCurveArcRadius( int nId, double dRad)
|
||||
ExeModifyArcRadius( int nId, double dRad)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
@@ -723,7 +723,7 @@ ExeModifyCurveArcRadius( int nId, double dRad)
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyCurveArcC2PN( int nId, const Point3d& ptEnd, int nRefType)
|
||||
ExeModifyArcC2P( int nId, const Point3d& ptEnd, int nRefType)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
@@ -754,7 +754,7 @@ ExeModifyCurveArcC2PN( int nId, const Point3d& ptEnd, int nRefType)
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyCurveArc3P( int nId, const Point3d& ptMid, int nRefType)
|
||||
ExeModifyArc3P( int nId, const Point3d& ptMid, int nRefType)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
@@ -781,6 +781,34 @@ ExeModifyCurveArc3P( int nId, const Point3d& ptMid, int nRefType)
|
||||
}
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyArcToExplementary( int nId)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
// recupero l'arco
|
||||
ICurveArc* pArc = GetCurveArc( pGeomDB->GetGeoObj( nId)) ;
|
||||
if ( pArc == nullptr)
|
||||
return false ;
|
||||
// eseguo trasformazione
|
||||
return pArc->ToExplementary() ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
bool
|
||||
ExeModifyArcByFlip( int nId)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
// recupero l'arco
|
||||
ICurveArc* pArc = GetCurveArc( pGeomDB->GetGeoObj( nId)) ;
|
||||
if ( pArc == nullptr)
|
||||
return false ;
|
||||
// eseguo trasformazione
|
||||
return pArc->Flip() ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
int
|
||||
ExeExplodeCurveCompo( int nId, int* pnCount)
|
||||
@@ -856,6 +884,7 @@ ExeApproxCurve( int nId, int nApprType, double dLinTol)
|
||||
bool bOk = ( pCurve != nullptr) ;
|
||||
// eseguo l'approssimazione
|
||||
const double ANG_TOL_MAX_DEG = 90 ;
|
||||
const double LIN_FEA_LEN_STD = 20 ;
|
||||
PtrOwner<ICurveComposite> pCC( CreateCurveComposite()) ;
|
||||
bOk = bOk && ! IsNull( pCC) ;
|
||||
if ( nApprType == APP_LINES ||
|
||||
@@ -866,7 +895,7 @@ ExeApproxCurve( int nId, int nApprType, double dLinTol)
|
||||
}
|
||||
else { // con bi-archi
|
||||
PolyArc PA ;
|
||||
bOk = bOk && pCurve->ApproxWithArcs( dLinTol, ANG_TOL_MAX_DEG, PA) && pCC->FromPolyArc( PA) ;
|
||||
bOk = bOk && pCurve->ApproxWithArcsEx( dLinTol, ANG_TOL_MAX_DEG, LIN_FEA_LEN_STD, PA) && pCC->FromPolyArc( PA) ;
|
||||
}
|
||||
// copio estrusione e spessore
|
||||
Vector3d vtExtr ;
|
||||
|
||||
Reference in New Issue
Block a user