EgtInterface 1.5j3 :

- aggiunte funzioni a API.
This commit is contained in:
Dario Sassi
2014-10-15 07:41:07 +00:00
parent aaaa45ef4e
commit 3b1e139286
3 changed files with 48 additions and 0 deletions
+38
View File
@@ -83,6 +83,44 @@ __stdcall EgtGetPrev( int nGseCtx, int nId)
return pGeomDB->GetPrev( nId) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetBBox( int nGseCtx, int nId, int nFlag, double ptMin[3], double ptMax[3])
{
IGeomDB* pGeomDB = GetGeomDB( nGseCtx) ;
VERIFY_GEOMDB( pGeomDB, GDB_ID_NULL)
// recupero il bounding box locale dell'oggetto
BBox3d b3Loc ;
if ( ! pGeomDB->GetLocalBBox( nId, b3Loc, nFlag))
return FALSE ;
ptMin[0] = b3Loc.GetMin().x ;
ptMin[1] = b3Loc.GetMin().y ;
ptMin[2] = b3Loc.GetMin().z ;
ptMax[0] = b3Loc.GetMax().x ;
ptMax[1] = b3Loc.GetMax().y ;
ptMax[2] = b3Loc.GetMax().z ;
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetBBoxGlob( int nGseCtx, int nId, int nFlag, double ptMin[3], double ptMax[3])
{
IGeomDB* pGeomDB = GetGeomDB( nGseCtx) ;
VERIFY_GEOMDB( pGeomDB, GDB_ID_NULL)
// recupero il bounding box globale dell'oggetto
BBox3d b3Loc ;
if ( ! pGeomDB->GetGlobalBBox( nId, b3Loc, nFlag))
return FALSE ;
ptMin[0] = b3Loc.GetMin().x ;
ptMin[1] = b3Loc.GetMin().y ;
ptMin[2] = b3Loc.GetMin().z ;
ptMax[0] = b3Loc.GetMax().x ;
ptMax[1] = b3Loc.GetMax().y ;
ptMax[2] = b3Loc.GetMax().z ;
return TRUE ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtCopy( int nGseCtx, int nSouId, int nRefId, int nSonBeforeAfter)