EgtExecutor :
- aggiunto flag bExact a VolZmapGetDepth di Exe e Lua.
This commit is contained in:
@@ -232,7 +232,7 @@ LuaVolZmapMillingStep( lua_State* L)
|
||||
static int
|
||||
LuaVolZmapGetDepth( lua_State* L)
|
||||
{
|
||||
// 3 o 4 parametri : nId, ptP, vtDir [, nRefType]
|
||||
// 3 o 4 o 5 parametri : nId, ptP, vtDir [, nRefType] [, bExact]
|
||||
int nId ;
|
||||
LuaCheckParam( L, 1, nId)
|
||||
Point3d ptP ;
|
||||
@@ -240,11 +240,15 @@ LuaVolZmapGetDepth( lua_State* L)
|
||||
Vector3d vtDir ;
|
||||
LuaCheckParam( L, 3, vtDir)
|
||||
int nRefType = RTY_DEFAULT ;
|
||||
LuaGetParam( L, 4, nRefType) ;
|
||||
bool bExact = false ;
|
||||
if ( LuaGetParam( L, 4, nRefType))
|
||||
LuaGetParam( L, 5, bExact) ;
|
||||
else
|
||||
LuaGetParam( L, 4, bExact) ;
|
||||
LuaClearStack( L) ;
|
||||
// eseguo calcolo profondità dal punto lungo la direzione
|
||||
double dLen1, dLen2 ;
|
||||
bool bOk = ExeVolZmapGetDepth( nId, ptP, vtDir, nRefType, dLen1, dLen2) ;
|
||||
bool bOk = ExeVolZmapGetDepth( nId, ptP, vtDir, nRefType, bExact, dLen1, dLen2) ;
|
||||
// restituisco il risultato
|
||||
if ( bOk) {
|
||||
LuaSetParam( L, dLen1) ;
|
||||
|
||||
Reference in New Issue
Block a user