EgtExecutor 1.8d1 :
- aggiunta funzione Exe e Lua GetAxisType.
This commit is contained in:
@@ -2494,6 +2494,16 @@ ExeGetAxisToken( const string& sAxis, string& sToken)
|
||||
return pMachMgr->GetAxisToken( sAxis, sToken) ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeGetAxisType( const string& sAxis, bool& bLinear)
|
||||
{
|
||||
IMachMgr* pMachMgr = GetCurrMachMgr() ;
|
||||
VERIFY_MACHMGR( pMachMgr, false)
|
||||
// recupero il tipo dell'asse
|
||||
return pMachMgr->GetAxisType( sAxis, bLinear) ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeGetAllHeadsNames( STRVECTOR& vNames)
|
||||
|
||||
Binary file not shown.
@@ -2927,6 +2927,25 @@ LuaGetAxisToken( lua_State* L)
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaGetAxisType( lua_State* L)
|
||||
{
|
||||
// 1 parametro : sAxis
|
||||
string sAxis ;
|
||||
LuaCheckParam( L, 1, sAxis)
|
||||
LuaClearStack( L) ;
|
||||
// recupero il tipo dell'asse
|
||||
bool bLinear ;
|
||||
bool bOk = ExeGetAxisType( sAxis, bLinear) ;
|
||||
// restituisco il risultato
|
||||
if ( bOk)
|
||||
LuaSetParam( L, bLinear) ;
|
||||
else
|
||||
LuaSetParam( L) ;
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaGetAllHeadsNames( lua_State* L)
|
||||
@@ -3269,6 +3288,7 @@ LuaInstallMachMgr( LuaMgr& luaMgr)
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetHeadId", LuaGetHeadId) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetHeadExitCount", LuaGetHeadExitCount) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetAxisToken", LuaGetAxisToken) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetAxisType", LuaGetAxisType) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetAllHeadsNames", LuaGetAllHeadsNames) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetAllTablesNames", LuaGetAllTablesNames) ;
|
||||
// Machine Calc
|
||||
|
||||
Reference in New Issue
Block a user