EgtInterface :

- aggiunte interfacce per nuove funzioni BeamMgr.
This commit is contained in:
Dario Sassi
2020-12-16 07:25:11 +00:00
parent 3a7c73790d
commit df8b3a0cb4
+114 -3
View File
@@ -27,7 +27,104 @@ __stdcall EgtInitBeamMgr( int nFlag)
return ( ExeInitBeamMgr( nFlag) ? TRUE : FALSE) ;
}
EXE_EXPORT int ExeBeamGetSolid( int nPartId) ;
//-----------------------------------------------------------------------------
int
__stdcall EgtBeamCreatePart( void)
{
return ExeBeamCreatePart() ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamSetPart( int nPartId)
{
return ( ExeBeamSetPart( nPartId) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamErasePart( void)
{
return ( ExeBeamErasePart() ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamSetPartProdNbr( int nProdNbr)
{
return ( ExeBeamSetPartProdNbr( nProdNbr) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamSetPartName( const wchar_t* wsName)
{
return ( ExeBeamSetPartName( wstrztoA( wsName)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamSetPartCount( int nCount)
{
return ( ExeBeamSetPartCount( nCount) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamSetPartBox( double dLength, double dHeight, double dWidth)
{
return ( ExeBeamSetPartBox( dLength, dHeight, dWidth) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtBeamAddProcess( int nGroup, int nProc, int nSide, const wchar_t* wsDes, int nProcId,
const double ptOrig[3], const double vX[3], const double vY[3], const double vZ[3],
int nPar, const double vPar[], const wchar_t* wsPar, BOOL bUpdate)
{
Frame3d frFrame ;
if ( ! frFrame.Set( ptOrig, vX, vY, vZ))
return GDB_ID_NULL ;
DBLVECTOR vdPar ;
vdPar.reserve( nPar) ;
for ( int i = 0 ; i < nPar ; ++i) {
vdPar.push_back( vPar[i]) ;
}
return ExeBeamAddProcess( nGroup, nProc, nSide, wstrztoA( wsDes), nProcId, frFrame,
vdPar, wstrztoA( wsPar), ( bUpdate != FALSE)) ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtBeamModifyProcess( int nGeomId, int nGroup, int nProc, int nSide, const wchar_t* wsDes, int nProcId,
const double ptOrig[3], const double vX[3], const double vY[3], const double vZ[3],
int nPar, const double vPar[], const wchar_t* wsPar, BOOL bUpdate)
{
Frame3d frFrame ;
if ( ! frFrame.Set( ptOrig, vX, vY, vZ))
return GDB_ID_NULL ;
DBLVECTOR vdPar ;
vdPar.reserve( nPar) ;
for ( int i = 0 ; i < nPar ; ++i) {
vdPar.push_back( vPar[i]) ;
}
return ExeBeamModifyProcess( nGeomId, nGroup, nProc, nSide, wstrztoA( wsDes), nProcId, frFrame,
vdPar, wstrztoA( wsPar), ( bUpdate != FALSE)) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamEraseProcess( int nGeomId, BOOL bUpdate)
{
return ( ExeBeamEraseProcess( nGeomId, ( bUpdate != FALSE)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamEnableProcess( int nGeomId, BOOL bEnable, BOOL bUpdate)
{
return ( ExeBeamEnableProcess( nGeomId, ( bEnable != FALSE), ( bUpdate != FALSE)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
@@ -44,8 +141,22 @@ __stdcall EgtBeamGetSolid( int nPartId)
}
//-----------------------------------------------------------------------------
BOOL __stdcall
EgtBeamShowSolid( int nPartId, BOOL bShow)
BOOL
__stdcall EgtBeamShowSolid( int nPartId, BOOL bShow)
{
return ( ExeBeamShowSolid( nPartId, ( bShow != FALSE)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamGetBuildingIsOn( void)
{
return ( ExeBeamGetBuildingIsOn() ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBeamShowBuilding( BOOL bShow)
{
return ( ExeBeamShowBuilding( ( bShow != FALSE)) ? TRUE : FALSE) ;
}