EgtExecutor 2.2l2 :
- aggiunto nuovo tipo di file BTLx (FT_BTLX = 19) - aggiunta funzione Exe e Lua ImportBtlx - aggiunte funzioni Exe e Lua per BeamMgr creazione e modifica travi e pareti e aggiunta features.
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
#include "/EgtDev/Include/EExImportCnc.h"
|
||||
#include "/EgtDev/Include/EExImportCsf.h"
|
||||
#include "/EgtDev/Include/EExImportBtl.h"
|
||||
#include "/EgtDev/Include/EExImportBtlx.h"
|
||||
#include "/EgtDev/Include/EExExportStl.h"
|
||||
#include "/EgtDev/Include/EExExportSvg.h"
|
||||
#include "/EgtDev/Include/EExExportDxf.h"
|
||||
@@ -68,6 +69,8 @@ ExeGetFileType( const string& sFilePath)
|
||||
return FT_CSF ;
|
||||
else if ( sFileExt == "BTL")
|
||||
return FT_BTL ;
|
||||
else if ( sFileExt == "BTLX")
|
||||
return FT_BTLX ;
|
||||
else if ( sFileExt == "PNG" || sFileExt == "JPG" || sFileExt == "JPEG" || sFileExt == "BMP")
|
||||
return FT_IMG ;
|
||||
else if ( sFileExt == "PNT" || sFileExt == "XYZ")
|
||||
@@ -128,6 +131,34 @@ ExeImportBtl( const string& sFilePath, int nFlag)
|
||||
return bOk ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeImportBtlx( const string& sFilePath, int nFlag)
|
||||
{
|
||||
GseContext* pGseCtx = GetCurrGseContext() ;
|
||||
VERIFY_CTX_GEOMDB( pGseCtx, false)
|
||||
bool bOk = true ;
|
||||
// importo il file BTLx
|
||||
// preparo l'importatore
|
||||
PtrOwner<IImportBtlx> pImpBtlx( MyCreateImportBtlx()) ;
|
||||
bOk = bOk && ! IsNull( pImpBtlx) ;
|
||||
// eseguo l'importazione (direttamente nella radice)
|
||||
bOk = bOk && pImpBtlx->Import( sFilePath, pGseCtx->m_pGeomDB, nFlag) ;
|
||||
// aggiorno stato file corrente
|
||||
if ( pGseCtx->m_sFilePath.empty())
|
||||
pGseCtx->m_sFilePath = sFilePath ;
|
||||
ExeSetModified() ;
|
||||
// se richiesto, salvo il comando Lua equivalente
|
||||
if ( IsCmdLog()) {
|
||||
string sLua = "EgtImportBtlx('" + StringToLuaString( sFilePath) + "'," +
|
||||
ToString( nFlag) + ")" +
|
||||
" -- Ok=" + ToString( bOk) ;
|
||||
LOG_INFO( GetCmdLogger(), sLua.c_str()) ;
|
||||
}
|
||||
// restituisco il risultato
|
||||
return bOk ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeImportCnc( const string& sFilePath, int nFlag)
|
||||
|
||||
Reference in New Issue
Block a user