EgtExecutor 1.9b1 :
- aggiunta funzione Exe e Lua VolZmapAvoidSphere - aggiunta funzione Lua EgtSetCurrFilePath - modifiche per pezzi piani nesting con bordi con due tagli sovrapposti a diversa inclinazione.
This commit is contained in:
+28
-2
@@ -476,7 +476,6 @@ ExeVolZmapAvoidBox( int nId, const Frame3d& frBox, const Vector3d& vtDiag, int n
|
||||
// recupero lo Zmap e calcolo collisione
|
||||
IVolZmap* pVZM = GetVolZmap( pGeomDB->GetGeoObj( nId)) ;
|
||||
bOk = bOk && ( pVZM != nullptr && pVZM->AvoidBox( frBoxL, vtDiag)) ;
|
||||
ExeSetModified() ;
|
||||
// se richiesto, salvo il comando Lua equivalente
|
||||
if ( IsCmdLog()) {
|
||||
string sLua = "EgtVolZmapAvoidBox(" + IdToString( nId) + ",{" +
|
||||
@@ -491,4 +490,31 @@ ExeVolZmapAvoidBox( int nId, const Frame3d& frBox, const Vector3d& vtDiag, int n
|
||||
}
|
||||
// restituisco risultato
|
||||
return bOk ;
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeVolZmapAvoidSphere( int nId, const Point3d& ptCen, double dRad, int nRefType)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
// recupero il riferimento locale
|
||||
Frame3d frLoc ;
|
||||
bool bOk = pGeomDB->GetGlobFrame( nId, frLoc) ;
|
||||
// porto in locale il centro della sfera
|
||||
Point3d ptCenL = GetPointLocal( pGeomDB, ptCen, nRefType, frLoc) ;
|
||||
// recupero lo Zmap e calcolo collisione
|
||||
IVolZmap* pVZM = GetVolZmap( pGeomDB->GetGeoObj( nId)) ;
|
||||
bOk = bOk && ( pVZM != nullptr && pVZM->AvoidSphere( ptCenL, dRad)) ;
|
||||
// se richiesto, salvo il comando Lua equivalente
|
||||
if ( IsCmdLog()) {
|
||||
string sLua = "EgtVolZmapAvoidSphere(" + IdToString( nId) + ",{" +
|
||||
ToString( ptCen) + "}," +
|
||||
ToString( dRad) + "," +
|
||||
RefTypeToString( nRefType) + ")" +
|
||||
" -- Ok=" + ToString( bOk) ;
|
||||
LOG_INFO( GetCmdLogger(), sLua.c_str()) ;
|
||||
}
|
||||
// restituisco risultato
|
||||
return bOk ;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user