39 Commits

Author SHA1 Message Date
Daniele Bariletti 303489452a - aggiunta interfaccia per EgtCopyCompoSubCurve e EgtCopyParamRange.
- cambio versione.
2025-03-27 10:20:45 +01:00
Dario Sassi e9615222be EgtInterface 2.7c3 :
- ricompilazione con cambio versione.
2025-03-26 11:30:30 +01:00
Dario Sassi 92769d6783 EgtInterface 2.7c2 :
- aggiunta interfaccia funzione EgtGetAllInfo
- piccola miglioria accodamento stringhe con separatore '\n'.
2025-03-22 18:07:41 +01:00
Dario Sassi 7659e40140 EgtInterface 2.7c1 :
- ricompilazione con cambio versione.
2025-03-13 19:19:16 +01:00
Dario Sassi d65f563ea9 EgtInterface 2.7b3 :
- aggiunta interfaccia per funzione EgtImportPly.
2025-03-02 19:44:54 +01:00
Dario Sassi f1f0f7198f EgtInterface 2.7b1 :
- ricompilazione con cambio versione.
2025-02-28 12:12:27 +01:00
Dario Sassi 74a00d54a5 EgtInterface 2.7a4 :
- aggiunta interfaccia per funzione EgtSetFixtureLink.
2025-01-31 09:01:32 +01:00
SaraP 60772489fb EgtInterface 2.7a2 :
- aggiunte interfacce per gestione camera prospettica.
2025-01-23 10:11:33 +01:00
Dario Sassi 4d3a19c18a EgtInterface 2.7a1 :
- cambio annuale di versione
- compilazione 32bit senza più limiti per Windows XP.
2025-01-09 18:01:25 +01:00
Dario Sassi 9b30bdfdda EgtInterface 2.6l3 :
- aggiornamento interfaccia funzione EgtImport3MF.
2024-12-17 10:24:40 +01:00
Dario Sassi f426e04657 EgtInterface 2.6l1 :
- aggiunta interfaccia per funzione EgtImportOff.
2024-11-29 18:57:48 +01:00
Dario Sassi 49364bc33c EgtInterface 2.6j4 :
- aggiunta interfaccia per funzione EgtSetFixtureMobile.
2024-10-31 18:33:21 +01:00
Dario Sassi ebfbd5e8f0 EgtInterface :
- aggiunta interfaccia per funzione EgtKeepAllDispAxes.
2024-10-16 19:50:41 +02:00
Dario Sassi afd3000a27 EgtInterface 2.6j3 :
- aggiunte in interfaccia funzioni EgtMoveDispAxis, EgtRemoveDispAxis, EgtGetAxisType e EgtGetAxisDir.
2024-10-15 17:37:13 +02:00
Dario Sassi 875656bbed EgtInterface 2.6j1 :
- aggiunta interfaccia per EgtSurfTmSetFaceColor
- modificata interfaccia per EgtSetMark.
2024-10-01 15:23:28 +02:00
Dario Sassi 8ccd525a3d EgtInterface 2.6i1 :
- ricompilazione con cambio versione.
2024-09-23 13:05:40 +02:00
Dario Sassi f97734d654 EgtInterface :
- modifica a interfaccia di EgtSetMarkAttribs (ora con due colori).
2024-08-22 09:15:20 +02:00
Dario Sassi d67c660e60 EgtInterface 2.6h2 :
- aggiunta interfaccia per funzione EgtSurfFrChunkCenter.
2024-08-21 14:40:58 +02:00
Dario Sassi a9ac0026e1 EgtInterface 2.6g5 :
- ricompilazione con cambio versione.
2024-07-18 20:20:50 +02:00
Dario Sassi 7b7b2f9726 EgtInterface 2.6g1 :
- ricompilazione con cambio versione.
2024-07-09 11:16:32 +02:00
Dario Sassi 039a6d731a EgtInterface :
- aggiunte interfacce per EgtCurveIsACircle, EgtCurveIsARectangle e EgtCurveIsATrapezoid.
2024-06-26 17:39:55 +02:00
Dario Sassi f93b500ce4 EgtInterface 2.6f4 :
- ricompilazione con cambio versione.
2024-06-26 08:44:45 +02:00
Dario Sassi 30b7624a78 EgtInterface 2.6f3 :
- ricompilazione con cambio versione.
2024-06-13 08:03:17 +02:00
Dario Sassi 22def7d324 EgtInterface 2.6f1 :
- ricompilazione con cambio versione.
2024-06-07 19:01:11 +02:00
Dario Sassi ac992fd113 EgtInterface 2.6e6 :
- aggiunta interfaccia per funzione EgtGetPreviewMachiningToolStepCount.
2024-05-30 15:22:18 +02:00
Dario Sassi d43f30c1f1 EgtInterface 2.6e1 :
- ricompilazione con cambio versione.
2024-05-06 09:05:52 +02:00
Dario Sassi c36fea7de7 EgtInterface 2.6d4 :
- aggiunta interfaccia per funzione EgtCreateArc2PR.
2024-04-19 17:52:07 +02:00
Dario Sassi fa91e49927 EgtInterface :
- aggiornato prototipo di EgtAdvancedImport per il nuovo parametro nFlag.
2024-04-13 17:22:04 +02:00
Dario Sassi 2261a9f4d1 EgtInterface 2.6d2 :
- aggiunta interfaccia per EgtGetNetHwKey.
2024-04-09 14:50:35 +02:00
Dario Sassi 5580700af2 EgtInterface 2.6d1 :
- modifiche a interfaccia di EgtCreateSurfTmSwept.
2024-04-05 16:53:27 +02:00
Dario Sassi 2cd376bbd8 EgtInterface 2.6c3 :
- aggiunta interfaccia EgtGetCalcAnglesEx
- modificate interfacce EgtGetCalcPositions, EgtGetCalcTipFromPositions e EgtGetCalcToolDirFromAngles.
2024-03-27 16:20:57 +01:00
Dario Sassi 4cc9be61d7 EgtInterface :
- aggiunte interfacce per EgtCreateAngularDimension, EgtCreateAngularDimensionEx, EgtCreateDiametralDimension e EgtCreateRadialDimension.
2024-03-14 20:03:38 +01:00
Dario Sassi f1fd976d13 EgtInterface :
- aggiunte interfacce per EgtSurfTmGetVertex, EgtSurfTmGetNearestVertex, EgtSurfTmMoveVertex e EgtSurfTmMoveFacet.
2024-03-13 09:25:47 +01:00
Dario Sassi 9d1a064611 EgtInterface 2.6c2 :
- ricompilazione con cambio versione.
2024-03-10 10:27:19 +01:00
Dario Sassi 97e1a108ba EgtInterface 2.6b3 :
- ricompilazione con cambio versione.
2024-02-16 08:48:22 +01:00
Dario Sassi 2d0397c826 EgtInterface 2.6b2 :
- ricompilazione con cambio versione.
2024-02-13 14:36:53 +01:00
Dario Sassi 34a116cfe9 EgtInterface 2.6a2 :
- aggiunta interfaccia per funzione EgtGetKeyAssLeftDays (numero di giorni mancanti al termine dell'assistenza).
2024-01-25 18:21:37 +01:00
Dario Sassi f9d1746fa8 EgtInterface :
- aggiunta interfaccia di funzione EgtChangeMachGroupName.
2024-01-16 19:43:28 +01:00
Dario Sassi e632c3be1c EgtInterface 2.6a1 :
- ricompilazione con cambio versione.
2024-01-16 15:51:29 +01:00
13 changed files with 446 additions and 67 deletions
+18 -4
View File
@@ -85,9 +85,23 @@ __stdcall EgtImportStl( const wchar_t* wsFilePath, double dScaleFactor)
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtImport3MF( const wchar_t* wsFilePath)
__stdcall EgtImportOff( const wchar_t* wsFilePath, double dScaleFactor)
{
return ( ExeImport3MF( wstrztoA( wsFilePath)) ? TRUE : FALSE) ;
return ( ExeImportOff( wstrztoA( wsFilePath), dScaleFactor) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtImportPly( const wchar_t* wsFilePath, double dScaleFactor)
{
return ( ExeImportPly( wstrztoA( wsFilePath), dScaleFactor) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtImport3MF( const wchar_t* wsFilePath, int nFlag)
{
return ( ExeImport3MF( wstrztoA( wsFilePath), nFlag) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
@@ -106,9 +120,9 @@ __stdcall EgtAdvancedImportIsEnabled( void)
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtAdvancedImport( const wchar_t* wsFilePath, double dLinToler)
__stdcall EgtAdvancedImport( const wchar_t* wsFilePath, double dLinToler, int nFlag)
{
return ( ExeAdvancedImport( wstrztoA( wsFilePath), dLinToler) ? TRUE : FALSE) ;
return ( ExeAdvancedImport( wstrztoA( wsFilePath), dLinToler, nFlag) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
+33 -1
View File
@@ -122,4 +122,36 @@ __stdcall EgtCreateAlignedDimension( int nParentId, const double ptP1[3], const
{
return ExeCreateAlignedDimension( nParentId, ptP1, ptP2, ptDim, wstrztoA( wsText), nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateAngularDimension( int nParentId, const double ptV[3], const double ptP1[3], const double ptP2[3],
const double ptDim[3], const wchar_t* wsText, int nRefType)
{
return ExeCreateAngularDimension( nParentId, ptV, ptP1, ptP2, ptDim, wstrztoA( wsText), nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateAngularDimensionEx( int nParentId, const double ptV1[3], const double ptP1[3],
const double ptV2[3], const double ptP2[3],
const double ptDim[3], const wchar_t* wsText, int nRefType)
{
return ExeCreateAngularDimensionEx( nParentId, ptV1, ptP1, ptV2, ptP2, ptDim, wstrztoA( wsText), nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateDiametralDimension( int nParentId, int nCrvId, const double ptDim[3],
const wchar_t* wsText, int nRefType)
{
return ExeCreateDiametralDimension( nParentId, nCrvId, ptDim, wstrztoA( wsText), nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateRadialDimension( int nParentId, int nCrvId, const double ptDim[3],
const wchar_t* wsText, int nRefType)
{
return ExeCreateRadialDimension( nParentId, nCrvId, ptDim, wstrztoA( wsText), nRefType) ;
}
+20
View File
@@ -129,14 +129,28 @@ int
__stdcall EgtCreateArc3P( int nParentId, const double ptP1[3],
const double ptP2[3], const double ptP3[3], int nRefType)
{
if ( ptP1 == nullptr || ptP2 == nullptr || ptP3 == nullptr)
return GDB_ID_NULL ;
return ExeCreateArc3P( nParentId, ptP1, ptP2, ptP3, nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateArc2PR( int nParentId, const double ptStart[3], const double ptEnd[3],
double dRad, BOOL bCCW, int nRefType)
{
if ( ptStart == nullptr || ptEnd == nullptr)
return GDB_ID_NULL ;
return ExeCreateArc2PR( nParentId, ptStart, ptEnd, dRad, ( bCCW != FALSE), nRefType) ;
}
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateArc2PD( int nParentId, const double ptStart[3], const double ptEnd[3],
double dDirSDeg, int nRefType)
{
if ( ptStart == nullptr || ptEnd == nullptr)
return GDB_ID_NULL ;
return ExeCreateArc2PD( nParentId, ptStart, ptEnd, dDirSDeg, nRefType) ;
}
@@ -146,6 +160,8 @@ __stdcall EgtCreateArc2PDEx( int nParentId, const double ptStart[3],
const double ptEnd[3], int nSep, int nId,
double dDirSDeg, int nRefType)
{
if ( ptStart == nullptr || ptEnd == nullptr)
return GDB_ID_NULL ;
return ExeCreateArc2PDEx( nParentId, ptStart, ptEnd, nSep, nId, dDirSDeg, nRefType) ;
}
@@ -154,6 +170,8 @@ int
__stdcall EgtCreateArc2PV( int nParentId, const double ptStart[3], const double ptEnd[3],
const double vtDirS[3], int nRefType)
{
if ( ptStart == nullptr || ptEnd == nullptr)
return GDB_ID_NULL ;
return ExeCreateArc2PV( nParentId, ptStart, ptEnd, vtDirS, nRefType) ;
}
@@ -162,6 +180,8 @@ int
__stdcall EgtCreateBiArc( int nParentId, const double ptStart[3], const double ptEnd[3],
double dDirSDeg, double dDirEDeg, double dPar, int nRefType)
{
if ( ptStart == nullptr || ptEnd == nullptr)
return GDB_ID_NULL ;
return ExeCreateBiArc( nParentId, ptStart, ptEnd, dDirSDeg, dDirEDeg, dPar, nRefType) ;
}
+3 -2
View File
@@ -157,9 +157,10 @@ __stdcall EgtCreateSurfTmByScrewing( int nParentId, int nCrvId,
//-------------------------------------------------------------------------------
int
__stdcall EgtCreateSurfTmSwept( int nParentId, int nSectId, int nGuideId, BOOL bCapEnds, double dLinTol)
__stdcall EgtCreateSurfTmSwept( int nParentId, int nSectId, int nGuideId, const double vtAx[3],
BOOL bCapEnds, double dLinTol, int nRefType)
{
return ExeCreateSurfTmSwept( nParentId, nSectId, nGuideId, ( bCapEnds != FALSE), dLinTol) ;
return ExeCreateSurfTmSwept( nParentId, nSectId, nGuideId, vtAx, ( bCapEnds != FALSE), dLinTol, nRefType) ;
}
//-------------------------------------------------------------------------------
+66
View File
@@ -68,6 +68,58 @@ __stdcall EgtCurveIsFlat( int nId, BOOL bUseExtrusion, double dToler, double vtN
return TRUE ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveIsACircle( int nId, double dToler, double ptC[3], double vtN[3], double* pdRad, BOOL* pbCCW)
{
if ( ptC == nullptr || vtN == nullptr || pdRad == nullptr || pbCCW == nullptr)
return FALSE ;
Point3d ptCen ;
Vector3d vtNorm ;
double dRad ;
bool bCCW ;
if ( ! ExeCurveIsACircle( nId, ptCen, vtNorm, dRad, bCCW, dToler))
return FALSE ;
VEC_FROM_3D( ptC, ptCen)
VEC_FROM_3D( vtN, vtNorm)
*pdRad = dRad ;
*pbCCW = ( bCCW ? TRUE : FALSE) ;
return TRUE ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveIsARectangle( int nId, double dToler, double ptP[3], double vtL1[3], double vtL2[3])
{
if ( ptP == nullptr || vtL1 == nullptr || vtL2 == nullptr)
return FALSE ;
Point3d ptPNT ;
Vector3d vtLato1, vtLato2 ;
if ( ! ExeCurveIsARectangle( nId, ptPNT, vtLato1, vtLato2, dToler))
return FALSE ;
VEC_FROM_3D( ptP, ptPNT)
VEC_FROM_3D( vtL1, vtLato1)
VEC_FROM_3D( vtL2, vtLato2)
return TRUE ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveIsATrapezoid( int nId, double dToler, double ptP[3], double vtB1[3], double vtL1[3], double vtB2[3])
{
if ( ptP == nullptr || vtB1 == nullptr || vtL1 == nullptr || vtB2 == nullptr)
return FALSE ;
Point3d ptPNT ;
Vector3d vtBase1, vtLato1, vtBase2 ;
if ( ! ExeCurveIsATrapezoid( nId, ptPNT, vtBase1, vtLato1, vtBase2, dToler))
return FALSE ;
VEC_FROM_3D( ptP, ptPNT)
VEC_FROM_3D( vtB1, vtBase1)
VEC_FROM_3D( vtL1, vtLato1)
VEC_FROM_3D( vtB2, vtBase2)
return TRUE ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtCurveAreaXY( int nId, double* pdArea)
@@ -218,3 +270,17 @@ __stdcall EgtCurveCompoCenter( int nId, int nSimpCrv, int nRefId, double ptCen[3
VEC_FROM_3D( ptCen, ptTmp)
return TRUE ;
}
//----------------------------------------------------------------------------
int
__stdcall EgtCopyCompoSubCurve( int nId, int nSubCrvToCopy, int nParentId)
{
return ExeCopyCompoSubCurve( nId, nSubCrvToCopy, nParentId) ;
}
//----------------------------------------------------------------------------
int
__stdcall EgtCopyParamRange( int nId, double dUStart, double dUEnd, int nParentId)
{
return ExeCopyParamRange( nId, dUStart, dUEnd, nParentId) ;
}
+62
View File
@@ -84,6 +84,24 @@ __stdcall EgtSurfFrChunkSimpleClassify( int nId1, int nChunk1, int nId2, int nCh
return ExeSurfFrChunkSimpleClassify( nId1, nChunk1, nId2, nChunk2, dToler) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfFrChunkCenter( int nId, int nChunk, int nRefId, double ptCen[3], double vtNorm[3])
{
// verifica parametri
if ( ptCen == nullptr || vtNorm == nullptr)
return FALSE ;
// recupero il centro e la normale
Point3d ptTmp ;
Vector3d vtN ;
if ( ! ExeSurfFrChunkCenter( nId, nChunk, nRefId, ptTmp, vtN))
return FALSE ;
// li assegno
VEC_FROM_3D( ptCen, ptTmp)
VEC_FROM_3D( vtNorm, vtN)
return TRUE ;
}
//----------------------------------------------------------------------------
int
__stdcall EgtExtractSurfFrChunkLoops( int nId, int nChunk, int nDestGrpId, int* pnCount)
@@ -112,11 +130,46 @@ __stdcall EgtSurfTmFacetFromTria( int nId, int nT)
return ExeSurfTmFacetFromTria( nId, nT) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmGetVertex( int nId, int nVert, int nRefId, double ptVert[3])
{
// verifica parametri
if ( ptVert == nullptr)
return FALSE ;
// recupero il vertice
Point3d ptV ;
if ( ! ExeSurfTmGetVertex( nId, nVert, nRefId, ptV))
return FALSE ;
// lo assegno
VEC_FROM_3D( ptVert, ptV)
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmGetNearestVertex( int nId, const double ptNear[3], int nRefId, int* pnVert, double ptVert[3])
{
// verifica parametri
if ( ptNear == nullptr || pnVert == nullptr || ptVert == nullptr)
return FALSE ;
// recupero indice del vertice e sue coordinate
Point3d ptTmp ;
if ( ! ExeSurfTmGetNearestVertex( nId, ptNear, nRefId, *pnVert, ptTmp))
return FALSE ;
// le assegno
VEC_FROM_3D( ptVert, ptTmp)
return TRUE ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmFacetNearestEndPoint( int nId, int nFacet, const double ptNear[3], int nRefId,
double ptEnd[3], double vtNorm[3])
{
// verifica parametri
if ( ptNear == nullptr || ptEnd == nullptr || vtNorm == nullptr)
return FALSE ;
// recupero il punto e la normale
Point3d ptTmp ;
Vector3d vtN ;
@@ -133,6 +186,9 @@ BOOL
__stdcall EgtSurfTmFacetNearestMidPoint( int nId, int nFacet, const double ptNear[3], int nRefId,
double ptMid[3], double vtNorm[3])
{
// verifica parametri
if ( ptNear == nullptr || ptMid == nullptr || vtNorm == nullptr)
return FALSE ;
// recupero il punto e la normale
Point3d ptTmp ;
Vector3d vtN ;
@@ -148,6 +204,9 @@ __stdcall EgtSurfTmFacetNearestMidPoint( int nId, int nFacet, const double ptNea
BOOL
__stdcall EgtSurfTmFacetCenter( int nId, int nFacet, int nRefId, double ptCen[3], double vtNorm[3])
{
// verifica parametri
if ( ptCen == nullptr || vtNorm == nullptr)
return FALSE ;
// recupero il centro e la normale
Point3d ptTmp ;
Vector3d vtN ;
@@ -163,6 +222,9 @@ __stdcall EgtSurfTmFacetCenter( int nId, int nFacet, int nRefId, double ptCen[3]
BOOL
__stdcall EgtSurfTmFacetNormVersor( int nId, int nFacet, int nRefId, double vtNorm[3])
{
// verifica parametri
if ( vtNorm == nullptr)
return FALSE ;
// recupero il vettore normale
Vector3d vtTmp ;
if ( ! ExeSurfTmFacetNormVersor( nId, nFacet, nRefId, vtTmp))
+21
View File
@@ -70,6 +70,20 @@ __stdcall EgtSurfFrOffset( int nId, double dDist, int nType)
return ( ExeSurfFrOffset( nId, dDist, nType) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmMoveVertex( int nId, int nVert, const double ptNewVert[3], int nRefType, BOOL bUpdate)
{
return ( ExeSurfTmMoveVertex( nId, nVert, ptNewVert, nRefType, ( bUpdate != FALSE)) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmMoveFacet( int nId, int nFacet, const double vtMove[3], int nRefType, BOOL bUpdate)
{
return ( ExeSurfTmMoveFacet( nId, nFacet, vtMove, nRefType, ( bUpdate != FALSE)) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
int
__stdcall EgtSurfTmToTriangles( int nId, int* pnCount)
@@ -119,6 +133,13 @@ __stdcall EgtSurfTmIntersect( int nId1, int nId2, BOOL bTwoColors)
return ( ExeSurfTmIntersect( nId1, nId2, ( bTwoColors != FALSE)) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmSetFaceColor( int nId, int nFacet, int nColor)
{
return ( ExeSurfTmSetFaceColor( nId, nFacet, nColor) ? TRUE : FALSE) ;
}
//----------------------------------------------------------------------------
BOOL
__stdcall EgtSurfTmResetTwoColors( int nId)
+21 -2
View File
@@ -108,9 +108,9 @@ __stdcall EgtGetCalcStatus( int nId, int* pnStat)
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetMark( int nId)
__stdcall EgtSetMark( int nId, int nMark)
{
return ( ExeSetMark( nId) ? TRUE : FALSE) ;
return ( ExeSetMark( nId, nMark) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
@@ -426,6 +426,25 @@ __stdcall EgtGetInfoFrame( int nId, const wchar_t* wsKey, double ptOrig[3],
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetAllInfo( int nId, wchar_t*& wsInfos)
{
if ( &wsInfos == nullptr)
return FALSE ;
STRVECTOR vsInfo ;
if ( ! ExeGetAllInfo( nId, vsInfo))
return FALSE ;
// restituzione vettore risultati
string sInfos ;
for ( const auto& sInfo : vsInfo)
sInfos += sInfo + "\n" ;
if ( ! sInfos.empty())
sInfos.pop_back() ;
wsInfos = _wcsdup( stringtoW( sInfos)) ;
return (( wsInfos == nullptr) ? FALSE : TRUE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtExistsInfo( int nId, const wchar_t* wsKey)
+16
View File
@@ -227,6 +227,15 @@ __stdcall EgtGetKeyLeftDays( int* pnLeftDays)
return ( ExeGetKeyLeftDays( *pnLeftDays) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetKeyAssLeftDays( int* pnAssLeftDays)
{
if ( pnAssLeftDays == nullptr)
return FALSE ;
return ( ExeGetKeyAssLeftDays( *pnAssLeftDays) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetKeyOptLeftDays( int* pnOptLeftDays)
@@ -236,6 +245,13 @@ __stdcall EgtGetKeyOptLeftDays( int* pnOptLeftDays)
return ( ExeGetKeyOptLeftDays( *pnOptLeftDays) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetNetHwKey( void)
{
return ( ExeGetNetHwKey() ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetOsInfo( wchar_t*& wsOs)
+167 -53
View File
@@ -72,21 +72,19 @@ __stdcall EgtGetMachines( wchar_t*& wsMachineNames, wchar_t*& wsMachineDirs)
return FALSE ;
// restituzione vettore nomi
string sMachineNames ;
for ( const auto& sName : vsMachineNames) {
if ( ! sMachineNames.empty())
sMachineNames += "\n" ;
sMachineNames += sName ;
}
for ( const auto& sName : vsMachineNames)
sMachineNames += sName + "\n" ;
if ( ! sMachineNames.empty())
sMachineNames.pop_back() ;
wsMachineNames = _wcsdup( stringtoW( sMachineNames)) ;
if ( wsMachineNames == nullptr)
return FALSE ;
// restituzione vettore direttori
string sMachineDirs ;
for ( const auto& sName : vsMachineDirs) {
if ( ! sMachineDirs.empty())
sMachineDirs += "\n" ;
sMachineDirs += sName ;
}
for ( const auto& sName : vsMachineDirs)
sMachineDirs += sName + "\n" ;
if ( ! sMachineDirs.empty())
sMachineDirs.pop_back() ;
wsMachineDirs = _wcsdup( stringtoW( sMachineDirs)) ;
if ( wsMachineDirs == nullptr) {
free( wsMachineNames) ;
@@ -198,6 +196,13 @@ __stdcall EgtRemoveMachGroup( int nMGroupId)
return ( ExeRemoveMachGroup( nMGroupId) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtChangeMachGroupName( int nMGroupInd, const wchar_t* wsNewName)
{
return ( ExeChangeMachGroupName( nMGroupInd, wstrztoA( wsNewName)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetMachGroupName( int nMGroupInd, wchar_t*& wsName)
@@ -589,6 +594,27 @@ __stdcall EgtShowOnlyTable( BOOL bVal)
return ( ExeShowOnlyTable( ( bVal != FALSE)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtMoveDispAxis( const wchar_t* wsName, double dPos)
{
return ( ExeMoveDispAxis( wstrztoA( wsName), dPos) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtRemoveDispAxis( const wchar_t* wsName)
{
return ( ExeRemoveDispAxis( wstrztoA( wsName)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtKeepAllDispAxes( int nSouPhase)
{
return ( ExeKeepAllDispAxes( nSouPhase) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtAddFixture( const wchar_t* wsName, const double ptPos[3], double dAngRotDeg, double dMov)
@@ -645,6 +671,13 @@ __stdcall EgtRotateFixture( int nFxtId, double dDeltaAngDeg)
return ( ExeRotateFixture( nFxtId, dDeltaAngDeg) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetFixtureLink( int nFxtId, const wchar_t* wsTaLink)
{
return ( ExeSetFixtureLink( nFxtId, wstrztoA( wsTaLink)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtMoveFixtureMobile( int nFxtId, double dDeltaMov)
@@ -652,6 +685,13 @@ __stdcall EgtMoveFixtureMobile( int nFxtId, double dDeltaMov)
return ( ExeMoveFixtureMobile( nFxtId, dDeltaMov) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetFixtureMobile( int nFxtId, double dMov)
{
return ( ExeSetFixtureMobile( nFxtId, dMov) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
// Tools DataBase
//-----------------------------------------------------------------------------
@@ -977,11 +1017,10 @@ __stdcall EgtTdbToBeImported( const wchar_t* wsFile, wchar_t*& wsToolsNames, int
return FALSE ;
// restituzione vettore nomi
string sToolsNames ;
for ( const auto& sName : vsToolsNames) {
if ( ! sToolsNames.empty())
sToolsNames += "\n" ;
sToolsNames += sName ;
}
for ( const auto& sName : vsToolsNames)
sToolsNames += sName + "\n" ;
if ( ! sToolsNames.empty())
sToolsNames.pop_back() ;
wsToolsNames = _wcsdup( stringtoW( sToolsNames)) ;
if ( wsToolsNames == nullptr)
return FALSE ;
@@ -1019,11 +1058,10 @@ __stdcall EgtTdbImport( const wchar_t* wsFile, const wchar_t* wsToolsToImport, c
if ( ! ExeTdbImport( string( wstrztoA( wsFile)), vsToolsToImport, vsToolsNames, vsImported))
return FALSE ;
string sImported ;
for ( const auto& sName : vsImported) {
if ( ! sImported.empty())
sImported += "\n" ;
sImported += sName ;
}
for ( const auto& sName : vsImported)
sImported += sName + "\n" ;
if ( ! sImported.empty())
sImported.pop_back() ;
wsImported = _wcsdup( stringtoW( sImported)) ;
return (( wsImported == nullptr) ? FALSE : TRUE) ;
}
@@ -1327,11 +1365,10 @@ __stdcall EgtMdbToBeImported( const wchar_t* wsFile, wchar_t*& wsMachiningsNames
return FALSE ;
// restituzione vettore nomi
string sMachiningsNames ;
for ( const auto& sName : vsMachiningsNames) {
if ( ! sMachiningsNames.empty())
sMachiningsNames += "\n" ;
sMachiningsNames += sName ;
}
for ( const auto& sName : vsMachiningsNames)
sMachiningsNames += sName + "\n" ;
if ( ! sMachiningsNames.empty())
sMachiningsNames.pop_back() ;
wsMachiningsNames = _wcsdup( stringtoW( sMachiningsNames)) ;
if ( wsMachiningsNames == nullptr)
return FALSE ;
@@ -1369,11 +1406,10 @@ __stdcall EgtMdbImport( const wchar_t* wsFile, const wchar_t* wsMachiningsToImpo
if ( ! ExeMdbImport( string( wstrztoA( wsFile)), vsMachiningsToImport, vsMachiningsNames, vsImported))
return FALSE ;
string sImported ;
for ( const auto& sName : vsImported) {
if ( ! sImported.empty())
sImported += "\n" ;
sImported += sName ;
}
for ( const auto& sName : vsImported)
sImported += sName + "\n" ;
if ( ! sImported.empty())
sImported.pop_back() ;
wsImported = _wcsdup( stringtoW( sImported)) ;
return (( wsImported == nullptr) ? FALSE : TRUE) ;
}
@@ -1727,9 +1763,16 @@ __stdcall EgtRemovePreviewMachiningTool( void)
//-----------------------------------------------------------------------------
int
__stdcall EgtPreviewMachiningTool( int nEntId, int nFlag)
__stdcall EgtGetPreviewMachiningToolStepCount( void)
{
return ExePreviewMachiningTool( nEntId, nFlag) ;
return ExeGetPreviewMachiningToolStepCount() ;
}
//-----------------------------------------------------------------------------
int
__stdcall EgtPreviewMachiningTool( int nEntId, int nStep)
{
return ExePreviewMachiningTool( nEntId, nStep) ;
}
//-----------------------------------------------------------------------------
@@ -2016,6 +2059,32 @@ __stdcall EgtGetHeadExitCount( const wchar_t* wsHead)
return ExeGetHeadExitCount( wstrztoA( wsHead)) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetAxisType( const wchar_t* wsAxis, BOOL* pbLinear)
{
if ( pbLinear == nullptr)
return FALSE ;
bool bLinear ;
if ( ! ExeGetAxisType( wstrztoA( wsAxis), bLinear))
return FALSE ;
*pbLinear = ( bLinear ? TRUE : FALSE) ;
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetAxisDir( const wchar_t* wsAxis, double vtDir[3])
{
if ( vtDir == nullptr)
return FALSE ;
Vector3d vtTmp ;
if ( ! ExeGetAxisDir( wstrztoA( wsAxis), vtTmp))
return FALSE ;
VEC_FROM_3D( vtDir, vtTmp) ;
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetAxisInvert( const wchar_t* wsAxis, BOOL* pbInvert)
@@ -2116,40 +2185,85 @@ __stdcall EgtGetCalcAngles( const double vtDirT[3], const double vtDirA[3],
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetCalcPositions( const double ptP[3], double dAngA, double dAngB,
int* pnStat, double* pdX, double* pdY, double* pdZ)
__stdcall EgtGetCalcAnglesEx( const double vtDirT[3], const double vtDirA[3],
int* pnStat, double*& vAngs1, double*& vAngs2, int* pnCount)
{
if ( ptP == nullptr ||
pnStat == nullptr || pdX == nullptr || pdY == nullptr || pdZ == nullptr)
if ( vtDirT == nullptr || vtDirA == nullptr ||
pnStat == nullptr || pnCount == nullptr || &vAngs1 == nullptr || &vAngs2 == nullptr)
return FALSE ;
return ( ExeGetCalcPositions( ptP, dAngA, dAngB, *pnStat, *pdX, *pdY, *pdZ) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetCalcTipFromPositions( double dX, double dY, double dZ, double dAngA, double dAngB,
BOOL bBottom, double ptTip[3])
{
Point3d ptTmp ;
if ( ! ExeGetCalcTipFromPositions( dX, dY, dZ, dAngA, dAngB, ( bBottom != FALSE), ptTmp))
DBLVECTOR vA1, vA2 ;
if ( ! ExeGetCalcAngles( vtDirT, vtDirA, *pnStat, vA1, vA2) || vA1.size() != vA2.size())
return FALSE ;
// ritorno i dati
if ( ptTip != nullptr)
VEC_FROM_3D( ptTip, ptTmp) ;
// restituzione vettori angoli
int nDim = int( vA1.size()) ;
if ( nDim == 0) {
vAngs1 = nullptr ;
vAngs2 = nullptr ;
}
else {
vAngs1 = (double*) malloc( nDim * sizeof( double)) ;
if ( vAngs1 == nullptr)
return FALSE ;
vAngs2 = (double*) malloc( nDim * sizeof( double)) ;
if ( vAngs2 == nullptr) {
free( vAngs1) ;
return FALSE ;
}
for ( int i = 0 ; i < nDim ; ++ i) {
vAngs1[i] = vA1[i] ;
vAngs2[i] = vA2[i] ;
}
}
*pnCount = nDim ;
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetCalcToolDirFromAngles( double dAngA, double dAngB, double vtDir[3])
__stdcall EgtGetCalcPositions( const double ptP[3], int nCount, const double dAngs[],
int* pnStat, double* pdX, double* pdY, double* pdZ)
{
DBLVECTOR vAng( 2) ; vAng[0] = dAngA ; vAng[1] = dAngB ;
if ( ptP == nullptr || dAngs == nullptr ||
pnStat == nullptr || pdX == nullptr || pdY == nullptr || pdZ == nullptr)
return FALSE ;
DBLVECTOR vAng ;
for ( int i = 0 ; i < nCount ; ++i)
vAng.push_back( dAngs[i]) ;
return ( ExeGetCalcPositions( ptP, vAng, *pnStat, *pdX, *pdY, *pdZ) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetCalcTipFromPositions( double dX, double dY, double dZ, int nCount, const double dAngs[],
BOOL bBottom, double ptTip[3])
{
if ( dAngs == nullptr || ptTip == nullptr)
return FALSE ;
DBLVECTOR vAng ;
for ( int i = 0 ; i < nCount ; ++i)
vAng.push_back( dAngs[i]) ;
Point3d ptTmp ;
if ( ! ExeGetCalcTipFromPositions( dX, dY, dZ, vAng, ( bBottom != FALSE), ptTmp))
return FALSE ;
// ritorno i dati
VEC_FROM_3D( ptTip, ptTmp) ;
return TRUE ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtGetCalcToolDirFromAngles( int nCount, const double dAngs[], double vtDir[3])
{
if ( dAngs == nullptr || vtDir == nullptr)
return FALSE ;
DBLVECTOR vAng ;
for ( int i = 0 ; i < nCount ; ++i)
vAng.push_back( dAngs[i]) ;
Vector3d vtTmp ;
if ( ! ExeGetCalcToolDirFromAngles( vAng, vtTmp))
return FALSE ;
// ritorno i dati
if ( vtDir != nullptr)
VEC_FROM_3D( vtDir, vtTmp) ;
VEC_FROM_3D( vtDir, vtTmp) ;
return TRUE ;
}
+16 -2
View File
@@ -59,9 +59,9 @@ __stdcall EgtSetLineAttribs( int nWidth)
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetMarkAttribs( const int MarkCol[4])
__stdcall EgtSetMarkAttribs( const int MarkCol[4], const int Mark2Col[4])
{
return ( ExeSetMarkAttribs( Color( MarkCol)) ? TRUE : FALSE) ;
return ( ExeSetMarkAttribs( Color( MarkCol), Color( Mark2Col)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
@@ -571,3 +571,17 @@ __stdcall EgtGetImage( int nShowMode, const int TopCol[4], const int BottomCol[4
return ( ExeGetImage( nShowMode, Color( TopCol), Color( BottomCol),
nWidth, nHeight, wstrztoA( wsName)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetCameraType( BOOL bOrthoOrPersp, BOOL bRedraw)
{
return ( ExeSetCameraType( ( bOrthoOrPersp != FALSE), ( bRedraw != FALSE)) ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtSetZoomType( int nZoomType, BOOL bRedraw)
{
return ( ExeSetZoomType( nZoomType, ( bRedraw != FALSE)) ? TRUE : FALSE) ;
}
BIN
View File
Binary file not shown.
+3 -3
View File
@@ -22,14 +22,14 @@
<ProjectGuid>{DF654897-F85B-4108-A621-F2C4AB099A48}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>EgtInterface</RootNamespace>
<WindowsTargetPlatformVersion>10.0.20348.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v141_xp</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -42,7 +42,7 @@
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v141_xp</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>