EgtInterface 1.6d2 :
- in Lua in tutte le operazioni con creazione di più entità restituisco Id prima e numero - in Lua aggiunto oggetto BBox3d (non ancora con tutte le funzionalità) - in Lua aggiunta creazione superficie da BBox3d - in Lua aggiunte funzioni per avere BBox3d di oggetti - in Lua aggiunta OutBox - in Lua aggiunte funzioni per MachMgr.
This commit is contained in:
@@ -71,7 +71,7 @@ EgtInvertSurface( const INTVECTOR& vIds)
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
int
|
||||
__stdcall EgtExtractSurfTmFacetLoops( int nId, int nFacet, int nDestGrpId)
|
||||
__stdcall EgtExtractSurfTmFacetLoops( int nId, int nFacet, int nDestGrpId, int* pnCount)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, GDB_ID_NULL)
|
||||
@@ -89,6 +89,7 @@ __stdcall EgtExtractSurfTmFacetLoops( int nId, int nFacet, int nDestGrpId)
|
||||
bOk = bOk && pStm->GetFacetLoops( nFacet, vPL) ;
|
||||
// dalle polilinee creo le curve e le inserisco nel DB
|
||||
int nFirstId = GDB_ID_NULL ;
|
||||
int nCount = 0 ;
|
||||
for ( size_t i = 0 ; i < vPL.size() ; ++ i) {
|
||||
// creo la curva
|
||||
PtrOwner<ICurveComposite> pCrvCompo( CreateCurveComposite()) ;
|
||||
@@ -100,6 +101,8 @@ __stdcall EgtExtractSurfTmFacetLoops( int nId, int nFacet, int nDestGrpId)
|
||||
bOk = bOk && ( nNewId != GDB_ID_NULL) ;
|
||||
if ( bOk && nFirstId == GDB_ID_NULL)
|
||||
nFirstId = nNewId ;
|
||||
if ( bOk)
|
||||
++ nCount ;
|
||||
}
|
||||
EgtSetModified() ;
|
||||
// se richiesto, salvo il comando Lua equivalente
|
||||
@@ -107,9 +110,11 @@ __stdcall EgtExtractSurfTmFacetLoops( int nId, int nFacet, int nDestGrpId)
|
||||
string sLua = "EgtExtractSurfTmFacetLoops(" + ToString( nId) + ",{" +
|
||||
ToString( nFacet) + "," +
|
||||
ToString( nDestGrpId) + ")" +
|
||||
" -- Id=" + ToString( nFirstId) ;
|
||||
" -- Id1=" + ToString( nFirstId) + ",Nbr=" + ToString( nCount) ;
|
||||
LOG_INFO( GetCmdLogger(), sLua.c_str()) ;
|
||||
}
|
||||
// restituisco l'identificativo della nuova entità
|
||||
// restituisco risultati
|
||||
if ( pnCount != nullptr)
|
||||
*pnCount = nCount ;
|
||||
return nFirstId ;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user