EgtExecutor 1.9f5 :
- aggiunte funzioni Exe e Lua CAvSetGenTool.
This commit is contained in:
@@ -49,6 +49,23 @@ ExeCAvSetAdvTool( double dToolLen, double dToolDiam, double dTipLen, double dTip
|
||||
return s_pCAvTlStm->SetAdvTool( dToolLen, dToolDiam / 2, dTipLen, dTipDiam / 2, dToolCornR) ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeCAvSetGenTool( int nToolSectId)
|
||||
{
|
||||
if ( IsNull( s_pCAvTlStm))
|
||||
return false ;
|
||||
// verifico DB geometrico
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
// recupero la sezione dell'utensile
|
||||
const ICurveComposite* pCC = GetCurveComposite( pGeomDB->GetGeoObj( nToolSectId)) ;
|
||||
if ( pCC == nullptr)
|
||||
return false ;
|
||||
// assegno i dati dell'utensile
|
||||
return s_pCAvTlStm->SetGenTool( pCC) ;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
double
|
||||
ExeCAvToolPosStm( const Point3d& ptP, const Vector3d& vtAx, int nSurfTmId, const Vector3d& vtMove, int nRefType)
|
||||
|
||||
Binary file not shown.
@@ -63,6 +63,21 @@ LuaCAvSetAdvTool( lua_State* L)
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaCAvSetGenTool( lua_State* L)
|
||||
{
|
||||
// 1 parametro : ToolSectId
|
||||
int nToolSectId ;
|
||||
LuaCheckParam( L, 1, nToolSectId)
|
||||
LuaClearStack( L) ;
|
||||
// assegno dati utensile generico per Collision Avoidance
|
||||
bool bOk = ExeCAvSetGenTool( nToolSectId) ;
|
||||
// restituisco il risultato
|
||||
LuaSetParam( L, bOk) ;
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaCAvToolPosStm( lua_State* L)
|
||||
@@ -118,6 +133,7 @@ LuaInstallCAvTool( LuaMgr& luaMgr)
|
||||
bool bOk = ( &luaMgr != nullptr) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtCAvSetStdTool", LuaCAvSetStdTool) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtCAvSetAdvTool", LuaCAvSetAdvTool) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtCAvSetGenTool", LuaCAvSetGenTool) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtCAvToolPosStm", LuaCAvToolPosStm) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtCAvToolPathStm", LuaCAvToolPathStm) ;
|
||||
return bOk ;
|
||||
|
||||
Reference in New Issue
Block a user