EgtInterface 1.6o3 :

- aggiornamenti vari.
This commit is contained in:
Dario Sassi
2016-03-29 09:09:13 +00:00
parent 46bc4842ff
commit 33603e5961
4 changed files with 98 additions and 1 deletions
+35
View File
@@ -49,6 +49,13 @@ __stdcall EgtApproxCurve( int nId, int nApprType, double dLinTol)
return ( ExeApproxCurve( nId, nApprType, dLinTol) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtProjectCurveOnPlane( int nId, const double ptP[3], const double vtN[3], int nRefType)
{
return ( ExeProjectCurveOnPlane( nId, ptP, vtN, nRefType) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtChangeClosedCurveStartPoint( int nId, const double ptP[3], int nRefType)
@@ -186,6 +193,34 @@ __stdcall EgtModifyArc3P( int nId, const double ptMid[3], int nRefType)
return ( ExeModifyArc3P( nId, ptMid, nRefType) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtCloseCurveCompo( int nId)
{
return ( ExeCloseCurveCompo( nId) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtAddCurveCompoLine( int nId, const double ptP[3], int nRefType)
{
return ( ExeAddCurveCompoLine( nId, ptP, nRefType) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtAddCurveCompoArcTg( int nId, const double ptP[3], int nRefType)
{
return ( ExeAddCurveCompoArcTg( nId, ptP, nRefType) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtAddCurveCompoArc2P( int nId, const double ptMid[3], const double ptP[3], int nRefType)
{
return ( ExeAddCurveCompoArc2P( nId, ptMid, ptP, nRefType) ? TRUE : FALSE) ;
}
//-------------------------------------------------------------------------------
BOOL
__stdcall EgtAddCurveCompoJoint( int nId, double dU)
+27
View File
@@ -375,6 +375,18 @@ __stdcall EgtFrameOCS( double ptO[3], double vtDirZ[3],
return TRUE ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtFrameGetType( const double ptOrig[3],
const double vtX[3], const double vtY[3], const double vtZ[3])
{
// costruisco il riferimento
Frame3d frTemp ;
frTemp.Set( ptOrig, vtX, vtY, vtZ) ;
// ne ricavo il tipo
return frTemp.GetType() ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtFrameTranslate( double ptOrig[3], double vtX[3], double vtY[3], double vtZ[3],
@@ -481,6 +493,21 @@ __stdcall EgtFrameLocToLoc( double ptOrig[3], double vtX[3], double vtY[3], doub
//-----------------------------------------------------------------------------
// BBox3d
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtBBoxTranslate( double ptMin[3], double ptMax[3],
const double vtMove[3])
{
// eseguo la trasformazione
BBox3d b3Temp ;
b3Temp.Set( ptMin, ptMax) ;
if ( ! b3Temp.Translate( vtMove))
return FALSE ;
// aggiorno i parametri del box
VEC_FROM_3D( ptMin, b3Temp.GetMin())
VEC_FROM_3D( ptMax, b3Temp.GetMax())
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
+36 -1
View File
@@ -213,11 +213,46 @@ __stdcall EgtCurveLengthAtPoint( int nId, const double ptOn[3], double dExtend,
return ( ExeCurveLengthAtPoint( nId, ptOn, dExtend, pdLen) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveIsClosed( int nId)
{
return ( ExeCurveIsClosed( nId) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveIsFlat( int nId, double vtN[3], double* pdDist)
{
if ( vtN == nullptr || pdDist == nullptr)
return FALSE ;
Plane3d Plane ;
if ( ! ExeCurveIsFlat( nId, Plane))
return FALSE ;
VEC_FROM_3D( vtN, Plane.vtN)
*pdDist = Plane.dDist ;
return true ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveAreaXY( int nId, double* pdArea)
{
return ( ExeCurveAreaXY( nId, pdArea) ? TRUE : FALSE) ;
return ( ExeCurveAreaXY( nId, *pdArea) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveArea( int nId, double vtN[3], double* pdDist, double* pdArea)
{
if ( vtN == nullptr || pdDist == nullptr || pdArea == nullptr)
return FALSE ;
Plane3d Plane ;
if ( ! ExeCurveArea( nId, Plane, *pdArea))
return FALSE ;
VEC_FROM_3D( vtN, Plane.vtN)
*pdDist = Plane.dDist ;
return true ;
}
//----------------------------------------------------------------------------
BIN
View File
Binary file not shown.