Compare commits

..

3 Commits

Author SHA1 Message Date
LorenzoM 077f6a8961 Sistemata interfaccia VolZmap 2022-01-21 12:51:39 +01:00
LorenzoM 6fe012f742 Merge commit 'e994bb1836410aaa59d3b616498ea1c23ed583c2' into TempForVmill 2022-01-10 10:21:30 +01:00
LorenzoM 18249487ca Recuperata interfaccia zmap da LoernzoM 2022-01-05 18:43:35 +01:00
117 changed files with 354 additions and 1631 deletions
-73
View File
@@ -1,73 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EE3DllMain.h Data : 14.11.23 Versione : 2.5k2
// Contenuto : Prototipi funzioni generali della DLL.
//
//
//
// Modifiche : 14.11.23 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include <string>
class ILogger ;
//----------------------- Macro per import/export ----------------------------
#undef EE3_EXPORT
#if defined( I_AM_EE3) // da definirsi solo nella DLL
#define EE3_EXPORT __declspec( dllexport)
#else
#define EE3_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
// E' necessaria l'interfaccia in C per caricare queste funzioni dinamicamente
extern "C" {
// restituisce la versione della Dll
EE3_EXPORT const char* GetEE3Version( void) ;
// permette di impostare il logger per la Dll
EE3_EXPORT void SetEE3Logger( ILogger* pLogger) ;
// imposta la chiave di protezione
EE3_EXPORT void SetEE3Key( const std::string& sKey) ;
// imposta se chiave hardware di rete
EE3_EXPORT void SetEE3NetHwKey( bool bNetHwKey) ;
}
//-----------------------------------------------------------------------------
#include "/EgtDev/Include/EGnStringUtils.h"
#include "/EgtDev/Include/EgtILogger.h"
#include "/EgtDev/Include/EgtKeyCodes.h"
#include "/EgtDev/Include/SELkKeyProc.h"
//-----------------------------------------------------------------------------
// Test della chiave per caricare la DLL
inline bool
TestKeyForEE3( const std::string& sKey, int nKeyOpt, ILogger* pLogger)
{
// verifico la chiave e le opzioni
unsigned int nOpt1, nOpt2 ;
int nOptExpDays ;
int nRet = GetKeyOptions( sKey, KEY_BASELIB_PROD, KEY_BASELIB_VER, KEY_BASELIB_LEV,
nOpt1, nOpt2, nOptExpDays) ;
if ( nRet != KEY_OK && ! EqualNoCase( sKey, "EE3Base")) {
if ( nRet != KEY_OK) {
std::string sErr = "Error on Key (EE3/" + ToString( nRet) + ")" ;
LOG_ERROR( pLogger, sErr.c_str()) ;
return false ;
}
if ( ( nOpt1 & ( KEYOPT_EEX_INPBASE|KEYOPT_EEX_EXPBASE)) == 0 ||
( nKeyOpt != 0 && ( nOpt1 & nKeyOpt) == 0) ||
nOptExpDays < GetCurrDay()) {
std::string sErr = "Warning on Key (EE3/OPT)" ;
LOG_ERROR( pLogger, sErr.c_str()) ;
return false ;
}
}
return true ;
}
-40
View File
@@ -1,40 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023
//----------------------------------------------------------------------------
// File : EE3Export3dm.h Data : 21.09.23 Versione :
// Contenuto : Dichiarazione della interfaccia IExport3dm.
//
//
//
// Modifiche : 21.09.23 DB Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
#undef EE3_EXPORT
#if defined( I_AM_EE3) // da definirsi solo nella DLL
#define EE3_EXPORT __declspec( dllexport)
#else
#define EE3_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
class __declspec( novtable) IExport3dm
{
public :
virtual ~IExport3dm( void) {}
virtual bool SetOptions( int nFilter) = 0 ;
virtual bool Export( IGeomDB* pGDB, int nId, const std::string& sFile) = 0 ;
} ;
//-----------------------------------------------------------------------------
extern "C" {
EE3_EXPORT IExport3dm* CreateExport3dm(void) ;
}
-39
View File
@@ -1,39 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023
//----------------------------------------------------------------------------
// File : EE3Import3dm.h Data : 26.06.23 Versione : 2.5f1
// Contenuto : Dichiarazione della interfaccia IImport3dm.
//
//
//
// Modifiche : 26.06.23 DB Creazione modulo.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
#undef EE3_EXPORT
#if defined( I_AM_EE3) // da definirsi solo nella DLL
#define EE3_EXPORT __declspec( dllexport)
#else
#define EE3_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
class __declspec( novtable) IImport3dm
{
public :
virtual ~IImport3dm( void) {}
virtual bool Import( const std::string& sFile, IGeomDB* pGDB, int nIdGroup,
double dTextHeight = 2.0, double dExtLine = 5.0, double dArrLen = 5.0, double dTextDist = 2.0,
bool bLenIsMM = true, int nDecDig = -2, std::string sFont = "ModernPropS.Nfe") = 0 ;
} ;
//-----------------------------------------------------------------------------
extern "C" {
EE3_EXPORT IImport3dm* CreateImport3dm( void) ;
}
+10 -12
View File
@@ -1,25 +1,23 @@
//----------------------------------------------------------------------------
// EgalTech 2020-2022
// EgalTech 2020-2020
//----------------------------------------------------------------------------
// File : EExBeamConst.h Data : 04.04.22 Versione : 2.4d2
// File : EExBeamConst.h Data : 30.08.20 Versione : 2.2i1
// Contenuto : Dichiarazione delle costanti per travi e pareti con BTL.
//
//
//
// Modifiche : 30.08.20 DS Creazione modulo.
// 04.04.22 DS Aggiunto EIBFLAG_TRIM_WITH_OUTLINE.
//
//
//----------------------------------------------------------------------------
#pragma once
//-----------------------------------------------------------------------------
enum EImBtlFlag { EIBFLAG_NONE = 0x0000,
EIBFLAG_FLAT_POS = 0x0001, // pezzi di piatto (prevale sul successivo)
EIBFLAG_VERT_POS = 0x0002, // pezzi in verticale
EIBFLAG_SPECIAL_TRIM = 0x0004, // trim speciale per pareti
EIBFLAG_TS3_POS = 0x0008, // pezzi come in TechnoEssetre (prevale sui precedenti POS)
EIBFLAG_SORT = 0x0010, // ordina i pezzi nel DB in base al nome
EIBFLAG_USEUATTR = 0x0020, // utilizza i parametri utente U per modificare la geometria delle features
EIBFLAG_OUTL_FLAT_POS = 0x0040, // pezzi secondo outline o di piatto (prevale sui precedenti POS)
EIBFLAG_TRIM_WITH_OUTLINE = 0x0080} ; // esegui il trim delle feature con l'outline (se presente)
enum EImBtlFlag { EIBFLAG_NONE = 0x0000,
EIBFLAG_FLAT_POS = 0x0001, // pezzi di piatto (prevale sul successivo)
EIBFLAG_VERT_POS = 0x0002, // pezzi in verticale
EIBFLAG_SPECIAL_TRIM = 0x0004, // trim speciale per pareti
EIBFLAG_TS3_POS = 0x0008, // pezzi come in TechnoEssetre (prevale sui precedenti POS)
EIBFLAG_SORT = 0x0010, // ordina i pezzi nel DB in base al nome
EIBFLAG_USEUATTR = 0x0020} ; // utilizza i parametri utente U per modificare la geometria delle features
+3 -7
View File
@@ -1,20 +1,19 @@
//----------------------------------------------------------------------------
// EgalTech 2020-2022
// EgalTech 2020-2021
//----------------------------------------------------------------------------
// File : EExBeamMgr.h Data : 06.07.22 Versione : 2.4g2
// File : EExBeamMgr.h Data : 01.06.21 Versione : 2.2f1
// Contenuto : Dichiarazione della interfaccia IBeamMgr.
//
//
//
// Modifiche : 30.08.20 DS Creazione modulo.
// 01.06.21 DS Aggiunti parametri vsUAtt per Process.
// 06.07.22 DS Aggiunta GetSideData.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include "/EgtDev/Include/EExBeamConst.h"
#include <string>
@@ -42,9 +41,6 @@ class __declspec( novtable) IBeamMgr
virtual bool SetPartName( const std::string& sName) = 0 ;
virtual bool SetPartCount( int nCount) = 0 ;
virtual bool SetPartBox( double dLength, double dHeight, double dWidth, bool bUpdate = true) = 0 ;
virtual bool GetSideData( int nSide, Frame3d& frRef, double& dLength, double& dWidth, double& dHeight) = 0 ;
virtual bool ShowFacesName( bool bShow) = 0 ;
virtual bool ShowLoadingSide( bool bShow, bool bFromLeft) = 0 ;
virtual int AddProcess( int nGroup, int nProc, int nSide, const std::string& sDes, int nProcId,
const Frame3d& frRef, const DBLVECTOR& vdPar, const std::string& sPar, const STRVECTOR& vsUAtt,
int nCrvId, int nCrv2Id, bool bUpdate = true) = 0 ;
-2
View File
@@ -34,8 +34,6 @@ extern "C" {
EEX_EXPORT void SetEExLogger( ILogger* pLogger) ;
// imposta la chiave di protezione
EEX_EXPORT void SetEExKey( const std::string& sKey) ;
// imposta se chiave hardware di rete
EEX_EXPORT void SetEExNetHwKey( bool bNetHwKey) ;
}
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGnCmdExecutor.h"
#include "/EgtDev/Include/EgnCmdExecutor.h"
class IGeomDB ;
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
-42
View File
@@ -1,42 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2022-2022
//----------------------------------------------------------------------------
// File : EExExportThreeJS.h Data : 22.10.22 Versione : 2.4j1
// Contenuto : Dichiarazione della interfaccia IExportStl.
//
//
//
// Modifiche : 22.10.22 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EExExportConst.h"
#include <string>
#include "/EgtDev/Include/EGrScene.h"
//----------------------- Macro per import/export ----------------------------
#undef EEK_EXPORT
#if defined( I_AM_EEX) // da definirsi solo nella DLL
#define EEX_EXPORT __declspec( dllexport)
#else
#define EEX_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
class __declspec( novtable) IExportThreeJS
{
public:
virtual ~IExportThreeJS( void) {}
virtual bool SetOptions( int nFilter) = 0 ;
virtual bool Export( IGeomDB* pGDB, int nId, IEGrScene* pScene, bool bUdm, const std::string& sFile) = 0 ;
} ;
//-----------------------------------------------------------------------------
extern "C" {
EEX_EXPORT bool SetThreeJSLibDir( const std::string& sThreeJSLibDir) ;
EEX_EXPORT IExportThreeJS* CreateExportThreeJS( void) ;
}
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
+1 -1
View File
@@ -14,7 +14,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkGeomDB.h"
#include "/EgtDev/Include/EgkGeomDB.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
+2 -5
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2023
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGkAngle.h Data : 10.02.23 Versione : 2.5b1
// File : EGkAngle.h Data : 14.07.14 Versione : 1.5g2
// Contenuto : Dichiarazione funzioni per gestione angoli.
//
//
@@ -27,6 +27,3 @@ EGK_EXPORT double AngleNearAngle( double dAngDeg, double dAngRefDeg) ;
EGK_EXPORT double DiffAngle( double dAng1Deg, double dAng2Deg) ;
EGK_EXPORT double MediaAngle( double dAng1Deg, double dAng2Deg, double dCoeff) ;
EGK_EXPORT bool AngleInSpan( double dAngDeg, double dAngRefDeg, double dAngSpanDeg) ;
EGK_EXPORT bool AngleInRange( double dAngDeg, double dAngMinDeg, double dAngMaxDeg) ;
EGK_EXPORT bool AdjustAngleInSpan( double& dAngDeg, double dAngRefDeg, double dAngSpanDeg) ;
EGK_EXPORT bool AdjustAngleInRange( double& dAngDeg, double dAngMinDeg, double dAngMaxDeg) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkArcCenTgCurvePnt.h Data : 15.03.15 Versione : 1.6c2
// File : EgkArcCenTgCurvePnt.h Data : 15.03.15 Versione : 1.6c2
// Contenuto : Dichiarazione funzioni per calcolo arco dati centro,
// tangente a curva e punto vicino a finale.
//
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkArcPntDirTgCurve.h Data : 13.03.15 Versione : 1.6c2
// File : EgkArcPntDirTgCurve.h Data : 13.03.15 Versione : 1.6c2
// Contenuto : Dichiarazione funzioni per calcolo arco dato punto iniziale
// direzione e tangente a curva.
//
+3 -6
View File
@@ -1,14 +1,13 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2023
// EgalTech 2014-2015
//----------------------------------------------------------------------------
// File : EGkArcSpecial.h Data : 04.08.23 Versione : 2.5h1
// File : EGkArcSpecial.h Data : 15.03.15 Versione : 1.6c2
// Contenuto : Dichiarazione funzioni per calcolo speciale archi.
//
//
//
// Modifiche : 12.06.14 DS Creazione modulo.
// 20.12.22 DS Aggiunta GetArc2PCN.
// 04.08.23 DS Aggiunta GetArc2PNB.
//
//
//----------------------------------------------------------------------------
@@ -28,6 +27,4 @@
//----------------------------------------------------------------------------
EGK_EXPORT ICurve* GetArc2PD( const Point3d& ptStart, const Point3d& ptEnd, double dDirStartDeg) ;
EGK_EXPORT ICurve* GetArc2PVN( const Point3d& ptStart, const Point3d& ptEnd, const Vector3d& vtDirS, const Vector3d& vtN) ;
EGK_EXPORT ICurve* GetArc2PNB( const Point3d& ptStart, const Point3d& ptEnd, const Vector3d& vtN, double dBulge) ;
EGK_EXPORT ICurve* GetArc3P( const Point3d& ptStart, const Point3d& ptOther, const Point3d& ptEnd, bool bCirc) ;
EGK_EXPORT ICurveArc* GetArc2PCN( const Point3d& ptStart, const Point3d& ptEnd, const Point3d& ptNearCen, const Vector3d& vtN) ;
+8 -46
View File
@@ -1,20 +1,19 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkBBox3d.h Data : 12.05.23 Versione : 2.5e3
// File : EGkBBox3d.h Data : 14.01.14 Versione : 1.5a4
// Contenuto : Dichiarazione della classe axis aligned bounding box BBox3d.
//
//
//
// Modifiche : 14.01.13 DS Creazione modulo.
// 17.08.22 DS Aggiunte GetDimX, GetDimY, GetDimZ.
// 12.05.23 DS Aggiunta Overlaps con Box su riferimento.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkPoint3d.h"
#include "/EgtDev/Include/EGKPoint3d.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
@@ -73,9 +72,6 @@ class EGK_EXPORT BBox3d
{ return m_ptMax ; }
bool GetMinMax( Point3d& ptMin, Point3d& ptMax) const ;
bool GetMinDim( Point3d& ptMin, double& dDimX, double& dDimY, double& dDimZ) const ;
double GetDimX( void) const ;
double GetDimY( void) const ;
double GetDimZ( void) const ;
bool GetCenterExtent( Point3d& ptCenter, Vector3d& vtExtent) const ;
bool GetCenter( Point3d& ptCenter) const ;
bool GetRadius( double& dRad) const ;
@@ -90,11 +86,10 @@ class EGK_EXPORT BBox3d
bool EnclosesXY( const Point3d& ptP) const ;
bool Encloses( const BBox3d& b3Box) const ;
bool EnclosesXY( const BBox3d& b3Box) const ;
bool Overlaps( const BBox3d& b3Box) const ;
bool OverlapsXY( const BBox3d& b3Box) const ;
bool Overlaps( const Frame3d& frBox, const BBox3d& b3Box) const ;
bool FindIntersection( const BBox3d& b3Box, BBox3d& b3Int) const ;
bool FindIntersectionXY( const BBox3d& b3Box, BBox3d& b3Int) const ;
bool Overlaps( const BBox3d& b3B) const ;
bool OverlapsXY( const BBox3d& b3B) const ;
bool FindIntersection( const BBox3d& b3B, BBox3d& b3Int) const ;
bool FindIntersectionXY( const BBox3d& b3B, BBox3d& b3Int) const ;
double SqDistFromPoint( const Point3d& ptP) const ;
double SqDistFromPointXY( const Point3d& ptP) const ;
double DistFromPoint( const Point3d& ptP) const
@@ -127,36 +122,3 @@ class EGK_EXPORT BBox3d
Point3d m_ptMin ;
Point3d m_ptMax ;
} ;
//----------------------------------------------------------------------------
//! Restituisce una copia in locale del box passato
//----------------------------------------------------------------------------
inline const BBox3d
GetToLoc( const BBox3d& b3Box, const Frame3d& frRef)
{
BBox3d b3New = b3Box ;
b3New.ToLoc( frRef) ;
return b3New ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in globale del box passato
//----------------------------------------------------------------------------
inline const BBox3d
GetToGlob( const BBox3d& b3Box, const Frame3d& frRef)
{
BBox3d b3New = b3Box ;
b3New.ToGlob( frRef) ;
return b3New ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia dal primo al secondo riferimento del box passato
//----------------------------------------------------------------------------
inline const BBox3d
GetLocToLoc( const BBox3d& b3Box, const Frame3d& frOri, const Frame3d& frDest)
{
BBox3d b3New = b3Box ;
b3New.LocToLoc( frOri, frDest) ;
return b3New ;
}
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkCurve.h"
#include "/EgtDev/Include/EgkCurve.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
+3 -3
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2020-2023
// EgalTech 2020-2020
//----------------------------------------------------------------------------
// File : EGkCDeClosedSurfTmClosedSurfTm.h Data : 14.06.23 Versione : 2.5f3
// File : EGkCDeSurfTmSurfTm.h Data : 13.11.20 Versione :
// Contenuto : Dichiarazione funzione verifica collisione tra
// SurfTm e SurfTm.
//
@@ -27,4 +27,4 @@
// di collisione o inconsistenza dei parametri di input.
// Le due superfici devono essere espresse nel medesimo sistema di riferimento.
// La distanza di sicurezza ha effetto solo se maggiore di EPS_SMALL.
EGK_EXPORT bool CDeClosedSurfTmClosedSurfTm( const ISurfTriMesh& SurfA, const ISurfTriMesh& SurfB, double dSafeDist) ;
EGK_EXPORT bool CDeClosedSurfTmClosedSurfTm( const SurfTriMesh& SurfA, const SurfTriMesh& SurfB, double dSafeDist) ;
+1 -1
View File
@@ -28,5 +28,5 @@
// Raggio principale R1, raggio secondario R2.
// Il toro è posto nel piano XY del suo riferimento, centrato sull'origine.
// La funzione restituisce true in caso di collisione.
EGK_EXPORT bool CDeConvexTorusClosedSurfTm( const Frame3d& frTorus, double dRad1, double dRad2,
EGK_EXPORT bool CDeConvexTorusClosedSurfTm( const Frame3d& frTorusFrame, double dRad1, double dRad2,
double dSafeDist, const ISurfTriMesh& tmSurf) ;
-31
View File
@@ -1,31 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGkCalcPocketing.h Data : 16.11.23 Versione : 2.5j1
// Contenuto : Calcolo dei percorsi elementari di pocketing.
//
//
//
// Modifiche : 16.11.23 RE Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkCurveComposite.h"
#include "/EgtDev/Include/EGkSurfFlatRegion.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
EGK_EXPORT bool CalcPocketing( const ISurfFlatRegion* pSfr, double dRad, double dStep, double dAngle, int nType,
bool bSmooth, ICRVCOMPOPOVECTOR& vCrv) ;
EGK_EXPORT bool CalcZigZagInfill( const ISurfFlatRegion* pSfr, double dStep, bool bSmooth, bool bRemoveOverlapLink,
ICRVCOMPOPOVECTOR& vCrvCompoRes) ;
+3 -1
View File
@@ -16,6 +16,7 @@
#include "/EgtDev/Include/EGkPointGrid3d.h"
#include "/EgtDev/Include/EGkGeoCollection.h"
#include <unordered_set>
class IGeomDB ;
@@ -58,6 +59,7 @@ class ChainCurves
EGK_EXPORT bool GetForkIds( INTVECTOR& vForkIds) ;
private :
typedef std::unordered_set<int> INTUSET ;
struct CrvData {
int nId ;
Point3d ptStart ;
@@ -90,7 +92,7 @@ class ChainCurves
private :
bool m_bAllowInvert ;
double m_dToler ;
INTUNORDSET m_sCrvId ;
INTUSET m_sCrvId ;
CRVDATAVECTOR m_vCrvData ;
PointGrid3d m_PointGrid ;
bool m_bFromNear ;
-28
View File
@@ -1,28 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2022-202
//----------------------------------------------------------------------------
// File : EGkCircle2Pe.h Data : 18.08.22 Versione : 2.4h2
// Contenuto : Dichiarazione funzioni per calcolo circonferenze per 2 punti
// diametrali.
//
//
// Modifiche : 18.08.22 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkCurveArc.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
EGK_EXPORT ICurveArc* GetCircle2P( const Point3d& ptP1, const Point3d& ptP2, const Vector3d& vtN) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkCircleCenTgCurve.h Data : 12.03.15 Versione : 1.6c2
// File : EgkCircleCenTgCurve.h Data : 12.03.15 Versione : 1.6c2
// Contenuto : Dichiarazione funzioni per calcolo circonferenze di centro
// dato tangenti a curve.
//
-4
View File
@@ -60,10 +60,6 @@ class Color
{ m_Col[ALPHA] = (( nAlpha < 0) ? 0 : (( nAlpha > MAX_ALPHA) ? MAX_ALPHA : nAlpha)) ; }
void SetAlpha( double dAlpha)
{ m_Col[ALPHA] = (( dAlpha < 0) ? 0 : (( dAlpha > 1) ? MAX_ALPHA : int( lround( dAlpha * MAX_ALPHA)))) ; }
void Intensify( double dCoeff)
{ Set( int( m_Col[RED] * dCoeff), int( m_Col[GREEN] * dCoeff), int( m_Col[BLUE] * dCoeff), m_Col[ALPHA]) ;
if ( dCoeff > 1 && m_Col[RED] < 64 && m_Col[GREEN] < 64 && m_Col[BLUE] < 64)
Set( 64, 64, 64, m_Col[ALPHA]) ; }
int GetIntRed( void) const
{ return m_Col[RED] ; }
int GetIntGreen( void) const
+1 -5
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGkCurve.h Data : 06.05.14 Versione : 1.5e3
// File : EgkCurve.h Data : 06.05.14 Versione : 1.5e3
// Contenuto : Dichiarazione della interfaccia ICurve.
//
//
@@ -19,8 +19,6 @@
#include "/EgtDev/Include/EGkPlane3d.h"
#include "/EgtDev/Include/EgtPointerOwner.h"
class Voronoi ;
//----------------------------------------------------------------------------
class __declspec( novtable) ICurve : public IGeoObj
{
@@ -33,7 +31,6 @@ class __declspec( novtable) ICurve : public IGeoObj
PP_END = 3} ; // punto coincidente con la fine
enum ApprLineType { APL_STD = 0, // approssimazione standard
APL_SPECIAL = 10, // come STD, per composite conserva estremi di curve componenti
APL_SPECIAL_INT = 20, // come SPECIAL, per composite anche almeno un interno di componenti non rettilinei
APL_LEFT = 1, // linee sempre a sinistra
APL_LEFT_CONVEX = 11, // linee sempre a sinistra convesse
APL_RIGHT = 2, // linee sempre a destra
@@ -94,7 +91,6 @@ class __declspec( novtable) ICurve : public IGeoObj
virtual bool TrimEndAtLen( double dLenTrim) = 0 ;
virtual bool ExtendStartByLen( double dLenExt) = 0 ;
virtual bool ExtendEndByLen( double dLenExt) = 0 ;
virtual Voronoi* GetVoronoiObject( void) const = 0 ;
} ;
//----------------------------------------------------------------------------
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkCurveArc.h Data : 22.11.13 Versione : 1.3a1
// File : EgkCurveArc.h Data : 22.11.13 Versione : 1.3a1
// Contenuto : Dichiarazione della interfaccia ICurveArc.
//
//
+2 -19
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGkCurveAux.h Data : 23.05.14 Versione : 1.5e9
// File : EgkCurveAux.h Data : 23.05.14 Versione : 1.5e9
// Contenuto : Dichiarazione funzioni ausiliarie per ICurve.
//
//
@@ -32,18 +32,14 @@ struct CNurbsData
bool bRat ; // flag di curva razionale (pesi non tutti unitari)
bool bPeriodic ; // flag per segnalare vettore dei nodi periodico
bool bClosed ; // flag di curva chiusa
bool bClamped ; // flag di curva clamped
bool bExtraKnotes ; // flag per segnalare presenza di nodi extra all'inizio e fine (totale 2)
DBLVECTOR vU ; // vettore dei nodi
PNTVECTOR vCP ; // vettore dei punti di controllo
DBLVECTOR vW ; // vettore dei pesi
CNurbsData( void) : nDeg( 0), bRat( false), bPeriodic( false), bClosed( false), bClamped( true), bExtraKnotes(false) {}
CNurbsData( void) : nDeg( 0), bRat( false), bPeriodic( false), bClosed( false), bExtraKnotes( false) {}
} ;
// N.B. : in caso la curva sia razionale i punti di controllo sono in forma NON OMOGENEA [ x, y, z, w] ( dove la forma OMOGENEA è [ w*x, w*y, w*z, w])
// tutte le operazioni richiedono la forma OMOGENEA, finite le quali posso riportarmi alla forma NON OMOGENEA
//----------------------------------------------------------------------------
//! Trasforma un arco in una nuova curva di Bezier semplice o composta
EGK_EXPORT ICurve* ArcToBezierCurve( const ICurve* pArc) ;
@@ -78,16 +74,3 @@ EGK_EXPORT ICurve* ProjectCurveOnPlane( const ICurve& crCrv, const Plane3d& plPl
//----------------------------------------------------------------------------
//! Uniforma la pendenza di una composita tra quota iniziale e finale assegnate
EGK_EXPORT bool AdjustCurveSlope( ICurveComposite* pCrv, double dNini, double dNfin) ;
//----------------------------------------------------------------------------
//! Calcolo del diagramma di Voronoi della curva, nei TempParam dei risultati la distanza
//! Per nBound tenere valore di default.
EGK_EXPORT bool CalcCurveVoronoiDiagram( const ICurve& crvC, ICURVEPOVECTOR& vCrvs, int nBound = 3) ;
//----------------------------------------------------------------------------
//! Calcolo del Medial Axis della curva (sottoinsieme del diagramma di Voronoi), nei TempParam dei risultati la distanza
EGK_EXPORT bool CalcCurveMedialAxis( const ICurve& crvC, ICURVEPOVECTOR& vCrvs, int nSide) ;
//----------------------------------------------------------------------------
//! Calcola l'offset completo di una curva
EGK_EXPORT bool CalcCurveFatCurve( const ICurve& crvC, ICURVEPOVECTOR& vCrvs, double dRadius, bool bSquareEnds, bool bSquareMids) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkCurveBezier.h Data : 22.11.13 Versione : 1.3a1
// File : EgkCurveBezier.h Data : 22.11.13 Versione : 1.3a1
// Contenuto : Dichiarazione della interfaccia ICurveBezier.
//
//
+5 -6
View File
@@ -1,13 +1,13 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2023
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkCurveByApprox.h Data : 28.07.23 Versione : 2.5g3
// File : EGkCurveByApprox.h Data : 23.07.15 Versione : 1.6g7
// Contenuto : Dichiarazione della classe CurveByApprox.
//
//
//
// Modifiche : 23.07.15 DS Creazione modulo.
// 28.07.23 DS GetArcs e GetArcsCorner.
//
//
//----------------------------------------------------------------------------
@@ -35,11 +35,10 @@ class CurveByApprox
EGK_EXPORT bool Reset( void) ;
EGK_EXPORT bool AddPoint( const Point3d& ptP) ;
EGK_EXPORT ICurve* GetCurve( int nType, double dLinTol, double dAngTolDeg, double dLinFea) ;
EGK_EXPORT bool GetArcs( double dLinTol, double dAngTolDeg, PolyArc& PA) ;
EGK_EXPORT bool GetArcsCorner( double dLinTol, double dAngTolDeg, double dLinFea, PolyArc& PA) ;
EGK_EXPORT bool GetArcs( double dLinTol, double dAngTolDeg, double dLinFea, PolyArc& PA) ;
public :
enum TYPE { ARCS = 0, ARCS_CORNER = 1, CUBIC_BEZIERS = 2} ;
enum TYPE { ARCS_CORNER = 1, CUBIC_BEZIERS = 2} ;
private :
bool CalcParameterization( void) ;
+4 -39
View File
@@ -1,15 +1,13 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2022
// EgalTech 2013-2021
//----------------------------------------------------------------------------
// File : EGkCurveComposite.h Data : 24.03.22 Versione : 2.4c2
// File : EgkCurveComposite.h Data : 03.04.21 Versione : 2.3g2
// Contenuto : Dichiarazione della interfaccia ICurveComposite.
//
//
//
// Modifiche : 22.11.13 DS Creazione modulo.
// 21.07.21 LM Aggiunto parametro opzionale a Set/GetCurveTempProp.
// 23.01.22 DS Aggiunti metodi IsARectangle e IsATrapezoid.
// 24.03.22 DS Aggiunto metodo AddLineTg.
//
//----------------------------------------------------------------------------
@@ -41,13 +39,12 @@ class __declspec( novtable) ICurveComposite : public ICurve
virtual const ICurve* GetLastCurve( void) const = 0 ;
virtual const ICurve* GetPrevCurve( void) const = 0 ;
virtual bool IsParamAtJoint( double dU) const = 0 ;
virtual ICurve* RemoveFirstOrLastCurve( bool bLast = true) = 0 ;
virtual ICurve* RemoveFirstOrLastCurve( bool bLast = true) = 0 ;
virtual bool ChangeStartPoint( double dU) = 0 ;
virtual bool AddPoint( const Point3d& ptStart) = 0 ;
virtual bool AddLine( const Point3d& ptNew, bool bEndOrStart = true) = 0 ;
virtual bool AddLineTg( double dLen, bool bEndOrStart = true) = 0 ;
virtual bool AddArc2P( const Point3d& ptOther, const Point3d& ptNew, bool bEndOrStart = true) = 0 ;
virtual bool AddArcTg( const Point3d& ptNew, bool bEndOrStart = true) = 0 ;
virtual bool AddArc2P( const Point3d& ptOther, const Point3d& ptNew, bool bEndOrStart = true) = 0 ;
virtual bool AddJoint( double dU) = 0 ;
virtual bool ModifyJoint( int nU, const Point3d& ptNewJoint) = 0 ;
virtual bool RemoveJoint( int nU) = 0 ;
@@ -56,20 +53,13 @@ class __declspec( novtable) ICurveComposite : public ICurve
virtual bool ModifyCurveToLine( int nCrv) = 0 ;
virtual bool ArcsToBezierCurves( void) = 0 ;
virtual bool ArcsBezierCurvesToArcsPerpExtr( double dLinTol, double dAngTolDeg) = 0 ;
virtual bool StraightArcsToLines( double dLinTol, double dAngTolDeg) = 0 ;
virtual bool MergeCurves( double dLinTol, double dAngTolDeg, bool bStartEnd = true, bool bNeedSameProp = false) = 0 ;
virtual bool RemoveSmallParts( double dLinTol, double dAngTolDeg) = 0 ;
virtual bool RemoveSmallDefects( double dLinTol, double dAngTolDeg, bool bAlsoSpikes = false) = 0 ;
virtual bool RemoveUndercutOnY( double dLinTol, double dAngTolDeg) = 0 ;
virtual bool IsAPoint( void) const = 0 ;
virtual bool IsALine( double dLinTol, Point3d& ptStart, Point3d& ptEnd) const = 0 ;
virtual bool IsACircle( double dLinTol, Point3d& ptCen, Vector3d& vtN, double& dRad, bool& bCCW) const = 0 ;
virtual bool IsARectangle( double dLinTol, Point3d& ptP, Vector3d& vtL1, Vector3d& vtL2) const = 0 ;
virtual bool IsATrapezoid( double dLinTol, Point3d& ptP, Vector3d& vtB1, Vector3d& vtL1, Vector3d& vtB2) const = 0 ;
virtual bool SetCurveTempProp( int nCrv, int nProp, int nPropInd = 0) = 0 ;
virtual bool GetCurveTempProp( int nCrv, int& nProp, int nPropInd = 0) const = 0 ;
virtual bool SetCurveTempParam( int nCrv, double dParam, int nParamInd = 0) = 0 ;
virtual bool GetCurveTempParam( int nCrv, double& dParam, int nParamInd = 0) const = 0 ;
} ;
//-----------------------------------------------------------------------------
@@ -87,31 +77,6 @@ inline ICurveComposite* GetCurveComposite( IGeoObj* pGObj)
{ if ( pGObj == nullptr || pGObj->GetType() != CRV_COMPO)
return nullptr ;
return (static_cast<ICurveComposite*>(pGObj)) ; }
inline ICurveComposite* ConvertCurveToComposite( IGeoObj* pGObj)
{ if ( pGObj == nullptr || ( pGObj->GetType() & GEO_CURVE) == 0) {
delete pGObj ;
return nullptr ;
}
ICurveComposite* pCrvCo = CreateCurveComposite() ;
if ( pCrvCo == nullptr) {
delete pGObj ;
return nullptr ;
}
ICurve* pCrv = static_cast<ICurve*>( pGObj) ;
Vector3d vtExtr ;
if ( pCrv->GetExtrusion( vtExtr) && ! vtExtr.IsSmall())
pCrvCo->SetExtrusion( vtExtr) ;
double dThick ;
if ( pCrv->GetThickness( dThick) && abs( dThick) > EPS_SMALL)
pCrvCo->SetThickness( dThick) ;
for ( int i = 0 ; i < 2 ; ++ i) {
int nProp = pCrv->GetTempProp( i) ;
if ( nProp != 0)
pCrvCo->SetTempProp( nProp, i) ;
}
pCrvCo->AddCurve( pCrv) ;
return pCrvCo ;
}
//----------------------------------------------------------------------------
// Raccolte di puntatori a ICurveComposite
+1 -8
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkCurveLine.h Data : 22.11.13 Versione : 1.3a1
// File : EgkCurveLine.h Data : 22.11.13 Versione : 1.3a1
// Contenuto : Dichiarazione della interfaccia ICurveLine.
//
//
@@ -45,10 +45,3 @@ inline ICurveLine* GetCurveLine( IGeoObj* pGObj)
{ if ( pGObj == nullptr || pGObj->GetType() != CRV_LINE)
return nullptr ;
return (static_cast<ICurveLine*>(pGObj)) ; }
//----------------------------------------------------------------------------
// Raccolte di puntatori a ICurveLine
typedef std::vector<const ICurveLine*> CICRVLINEVECTOR ; // vettore di puntatori a const ICurveLine
typedef std::vector<ICurveLine*> ICRVLINEPVECTOR ; // vettore di puntatori a ICurveLine
typedef std::list<ICurveLine*> ICRVLINEPLIST ; // lista di puntatori a ICurveLine
typedef std::vector<PtrOwner<ICurveLine>> ICRVLINEPOVECTOR ; // vettore di puntatori esclusivi a ICurveLine
+1 -1
View File
@@ -14,7 +14,7 @@
#pragma once
#include "/EgtDev/Include/EGkCurve.h"
#include "/EgtDEv/Include/EGkGeomDB.h"
#include "/EgtDEv/Include/EgkGeomDB.h"
//-----------------------------------------------------------------------------
class CurveLocal
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkCurvePointDiffGeom.h Data : 26.12.13 Versione : 1.4l4
// File : EgkCurvePointDiffGeom.h Data : 26.12.13 Versione : 1.4l4
// Contenuto : Tipi generali per calcoli geometrici.
//
//
+16 -17
View File
@@ -49,23 +49,22 @@ class DistPointCurve
// Il flag bIsSegment vale solo per linee.
public :
EGK_EXPORT bool GetSqDist( double& dSqDist) const ;
EGK_EXPORT bool GetDist( double& dDist) const ;
EGK_EXPORT bool IsEpsilon( double dTol) const
{ double dSqDist ; return ( GetSqDist( dSqDist) && ( dSqDist < SQ_EPS_ZERO || dSqDist < dTol * dTol)) ; }
EGK_EXPORT bool IsSmall( void) const
{ return IsEpsilon( EPS_SMALL) ; }
EGK_EXPORT bool IsZero( void) const
{ return IsEpsilon( EPS_ZERO) ; }
EGK_EXPORT int GetNbrMinDist( void) const
{ return (int) m_Info.size() ; }
EGK_EXPORT bool GetMinDistPoint( int nInd, Point3d& ptMinDist, int& nFlag) const ;
EGK_EXPORT bool GetMinDistPoint( double dNearParam, Point3d& ptMinDist, int& nFlag) const ;
EGK_EXPORT bool GetParamAtMinDistPoint( int nInd, double& dParam, int& nFlag) const ;
EGK_EXPORT bool GetParamAtMinDistPoint( double dNearParam, double& dParam, int& nFlag) const ;
EGK_EXPORT bool GetSideAtMinDistPoint( int nInd, const Vector3d& vtN, int& nSide) const ;
EGK_EXPORT bool GetSideAtMinDistPoint( double dNearParam, const Vector3d& vtN, int& nSide) const ;
EGK_EXPORT bool GetMinDistInfo( int nInd, MinDistPCInfo& aInfo) const ;
EGK_EXPORT bool GetSqDist( double& dSqDist) ;
EGK_EXPORT bool GetDist( double& dDist) ;
EGK_EXPORT bool IsEpsilon( double dTol)
{ double dSqDist ; return ( GetSqDist( dSqDist) && ( dSqDist < SQ_EPS_ZERO || dSqDist < dTol * dTol)) ; }
EGK_EXPORT bool IsSmall( void)
{ return IsEpsilon( EPS_SMALL) ; }
EGK_EXPORT bool IsZero( void)
{ return IsEpsilon( EPS_ZERO) ; }
EGK_EXPORT int GetNbrMinDist( void) { return (int) m_Info.size() ; }
EGK_EXPORT bool GetMinDistPoint( int nInd, Point3d& ptMinDist, int& nFlag) ;
EGK_EXPORT bool GetMinDistPoint( double dNearParam, Point3d& ptMinDist, int& nFlag) ;
EGK_EXPORT bool GetParamAtMinDistPoint( int nInd, double& dParam, int& nFlag) ;
EGK_EXPORT bool GetParamAtMinDistPoint( double dNearParam, double& dParam, int& nFlag) ;
EGK_EXPORT bool GetSideAtMinDistPoint( int nInd, const Vector3d& vtN, int& nSide) ;
EGK_EXPORT bool GetSideAtMinDistPoint( double dNearParam, const Vector3d& vtN, int& nSide) ;
EGK_EXPORT bool GetMinDistInfo( int nInd, MinDistPCInfo& aInfo) ;
private :
DistPointCurve( void) ;
+10 -22
View File
@@ -1,13 +1,13 @@
//----------------------------------------------------------------------------
// EgalTech 2018-2023
// EgalTech 2018-2018
//----------------------------------------------------------------------------
// File : EGkDistPointSurfTm.h Data : 06.07.23 Versione : 2.5g1
// File : EGkDistPointTria.h Data : 11.12.18 Versione : 1.9l2
// Contenuto : Dichiarazione della classe distanza Punto da Trimesh.
//
//
//
// Modifiche : 06.12.18 LM Creazione modulo.
// 06.07.23 DS Aggiunta GetSurfTmNearestVertex.
//
//
//----------------------------------------------------------------------------
@@ -23,13 +23,6 @@
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
// Calcola la distanza tra punto e superficie trimesh.
// Risultati :
// - distanza
// - punto sulla superficie a minima distanza
// - indice del triangolo su cui giace il punto
// - indicazione se il punto di riferimento è dalla parte interna o esterna della superficie.
//----------------------------------------------------------------------------
class DistPointSurfTm
{
@@ -37,16 +30,16 @@ class DistPointSurfTm
EGK_EXPORT DistPointSurfTm( const Point3d& ptP, const ISurfTriMesh& tmSurf) ;
public :
EGK_EXPORT bool GetDist( double& dDist) const ;
EGK_EXPORT bool IsEpsilon( double dTol) const
EGK_EXPORT bool GetDist( double& dDist) ;
EGK_EXPORT bool IsEpsilon( double dTol)
{ return ( m_dDist >= 0. && ( m_dDist < EPS_ZERO || m_dDist < dTol)) ; }
EGK_EXPORT bool IsSmall( void) const
EGK_EXPORT bool IsSmall( void)
{ return IsEpsilon( EPS_SMALL) ; }
EGK_EXPORT bool IsZero( void) const
EGK_EXPORT bool IsZero( void)
{ return IsEpsilon( EPS_ZERO) ; }
EGK_EXPORT bool GetMinDistPoint( Point3d& ptMinDistPoint) const ;
EGK_EXPORT bool GetMinDistTriaIndex( int& nMinDistTriaIndex) const ;
EGK_EXPORT bool IsPointInside( void) const
EGK_EXPORT bool GetMinDistPoint( Point3d& ptMinDistPoint) ;
EGK_EXPORT bool GetMinDistTriaIndex( int& nMinDistTriaIndex) ;
EGK_EXPORT bool IsPointInside( void)
{ return m_bIsInside ; }
private :
@@ -58,8 +51,3 @@ class DistPointSurfTm
int m_nMinDistTriaIndex ;
bool m_bIsInside ;
} ;
//----------------------------------------------------------------------------
// Calcola l'indice del vertice della superficie a minima distanza dal punto di riferimento.
//----------------------------------------------------------------------------
EGK_EXPORT int GetSurfTmNearestVertex( const Point3d& ptP, const ISurfTriMesh& tmSurf) ;
+2 -4
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2020
//----------------------------------------------------------------------------
// File : EGkDllMain.h Data : 19.09.20 Versione : 2.2i2
// File : EgkDllMain.h Data : 19.09.20 Versione : 2.2i2
// Contenuto : Prototipi funzioni generali della DLL.
//
//
@@ -38,8 +38,6 @@ EGK_EXPORT void SetEGkLogger( ILogger* pLogger) ;
EGK_EXPORT void SetEGkKey( const std::string& sKey) ;
// imposta il tipo di chiave di protezione
EGK_EXPORT void SetEGkKeyType( int nType) ;
// imposta se chiave hardware di rete
EGK_EXPORT void SetEGkNetHwKey( bool bNetHwKey) ;
// permette di inizializzare il font manager
EGK_EXPORT void InitFontManager( const std::string& sNfeFontDir, const std::string& sDefaultFont) ;
// restituisce il direttorio dei font proprietari (Nfe)
@@ -47,4 +45,4 @@ EGK_EXPORT const std::string& GetNfeFontDir( void) ;
// restituisce il nome del font di default
EGK_EXPORT const std::string& GetDefaultFont( void) ;
// imposto il gestore eventi
EGK_EXPORT bool SetEGkProcessEvents( pfProcEvents pFun) ;
EGK_EXPORT bool SetEGkProcessEvents( pfProcEvents pFun) ;
-6
View File
@@ -32,12 +32,6 @@ class __declspec( novtable) IExtDimension : public IGeoObj
int nDecDigit, const std::string& sFont, double dTextHeight) = 0 ;
virtual bool SetLinear( const Point3d& ptP1, const Point3d& ptP2, const Point3d& ptPos,
const Vector3d& vtN, const Vector3d& vtDir, const std::string& sText) = 0 ;
virtual bool SetRadial( const Point3d& ptCen, const Point3d& ptPos,
const Vector3d& vtN, const std::string& sText) = 0 ;
virtual bool SetDiametral( const Point3d& ptCen, const Point3d& ptPos,
const Vector3d& vtN, const std::string& sText) = 0 ;
virtual bool SetAngular( const Point3d& ptP1, const Point3d& ptP2, const Point3d& ptV, const Point3d& ptPos,
const Vector3d& vtN, const std::string& sText ) = 0 ;
virtual const Vector3d& GetNormVersor( void) const = 0 ;
virtual const Vector3d& GetDirVersor( void) const = 0 ;
virtual const std::string& GetText( void) const = 0 ;
+24 -66
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkFrame3d.h Data : 20.07.23 Versione : 2.5g2
// File : EgkFrame3d.h Data : 30.05.14 Versione : 1.5e10
// Contenuto : Dichiarazione della classe Reference Frame 3d.
//
//
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkPoint3d.h"
#include "/EgtDev/Include/EGKPoint3d.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
@@ -30,8 +30,8 @@ class EGK_EXPORT Frame3d
enum Type { ERR = 0, TOP = 1, BOTTOM = 2, FRONT = 3,
BACK = 4, LEFT = 5, RIGHT = 6, GEN = 7} ;
public :
Frame3d( bool bGlob = true)
: m_nType( bGlob ? TOP : ERR), m_nZType( bGlob ? TOP : ERR), m_ptOrig( ORIG),
Frame3d( void)
: m_nType( TOP), m_nZType( TOP), m_ptOrig( ORIG),
m_vtVersX( X_AX), m_vtVersY( Y_AX), m_vtVersZ( Z_AX) {}
Frame3d( const Point3d& ptOrig)
: m_nType( TOP), m_nZType( TOP), m_ptOrig( ptOrig),
@@ -43,7 +43,7 @@ class EGK_EXPORT Frame3d
bool Set( const Point3d& ptOrig, const Vector3d& vtDirZ, const Vector3d& vtNearDirX) ;
bool Set( const Point3d& ptOrig, Type nType) ;
bool Set( const Point3d& ptOrig, double dAngCDeg, double dAngADeg, double dAngC1Deg) ;
bool Reset( bool bGlob = true) ;
bool Reset( void) ;
bool ChangeOrig( const Point3d& ptOrig) ;
bool Translate( const Vector3d& vtMove) ;
bool Rotate( const Point3d& ptAx, const Vector3d& vtAx, double dAngDeg) ;
@@ -56,23 +56,23 @@ class EGK_EXPORT Frame3d
bool ToLoc( const Frame3d& frRef) ;
bool LocToLoc( const Frame3d& frOri, const Frame3d& frDest) ;
Frame3d& operator*=( const Frame3d& frRef)
{ ToGlob( frRef) ; return *this ; }
{ this->ToGlob( frRef) ; return *this ;}
Frame3d& operator/=( const Frame3d& frRef)
{ ToLoc( frRef) ; return *this ; }
{ this->ToLoc( frRef) ; return *this ;}
bool IsValid( void) const
{ return ( m_nType != ERR) ; }
int GetType( void) const
{ return m_nType ; }
{ return m_nType ;}
int GetZType( void) const
{ return m_nZType ; }
{ return m_nZType ;}
const Point3d& Orig( void) const
{ return m_ptOrig ; }
{ return m_ptOrig ;}
const Vector3d& VersX( void) const
{ return m_vtVersX ; }
{ return m_vtVersX ;}
const Vector3d& VersY( void) const
{ return m_vtVersY ; }
{ return m_vtVersY ;}
const Vector3d& VersZ( void) const
{ return m_vtVersZ ; }
{ return m_vtVersZ ;}
bool GetRotationsCAC1( double& dAngC, double& dAngA, double& dAngC1) const ;
bool GetFixedAxesRotationsABC( double& dAngADeg, double& dAngBDeg, double& dAngCDeg) const ;
@@ -97,56 +97,23 @@ const Frame3d GLOB_FRM ;
//----------------------------------------------------------------------------
// Prodotto di due frame (porta il primo dal secondo nel globale)
//----------------------------------------------------------------------------
inline const Frame3d
operator*( const Frame3d& frRef, const Frame3d& frOri)
inline Frame3d
operator*( const Frame3d& frRef1, const Frame3d& frRef2)
{
Frame3d frNew = frRef ;
frNew.ToGlob( frOri) ;
return frNew ;
Frame3d frRefR = frRef1 ;
frRefR.ToGlob( frRef2) ;
return frRefR ;
}
//----------------------------------------------------------------------------
// Divisione di due frame (porta il primo dal globale nel secondo)
//----------------------------------------------------------------------------
inline const Frame3d
operator/( const Frame3d& frRef, const Frame3d& frDest)
inline Frame3d
operator/( const Frame3d& frRef1, const Frame3d& frRef2)
{
Frame3d frNew = frRef ;
frNew.ToLoc( frDest) ;
return frNew ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in locale del frame passato
//----------------------------------------------------------------------------
inline const Frame3d
GetToLoc ( const Frame3d& frRef, const Frame3d& frDest)
{
Frame3d frNew = frRef ;
frNew.ToLoc( frDest) ;
return frNew ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in globale del frame passato
//----------------------------------------------------------------------------
inline const Frame3d
GetToGlob( const Frame3d& frRef, const Frame3d& frOri)
{
Frame3d frNew = frRef ;
frNew.ToGlob( frOri) ;
return frNew ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia dal primo al secondo riferimento del frame passato
//----------------------------------------------------------------------------
inline const Frame3d
GetLocToLoc( const Frame3d& frRef, const Frame3d& frOri, const Frame3d& frDest)
{
Frame3d frNew = frRef ;
frNew.LocToLoc( frOri, frDest) ;
return frNew ;
Frame3d frRefR = frRef1 ;
frRefR.ToLoc( frRef2) ;
return frRefR ;
}
//----------------------------------------------------------------------------
@@ -167,12 +134,3 @@ AreSameFrame( const Frame3d& frRef1, const Frame3d& frRef2)
return false ;
return true ;
}
//----------------------------------------------------------------------------
// Verifica se il riferimento coincide con quello globale (o identità)
//----------------------------------------------------------------------------
inline bool
IsGlobFrame( const Frame3d& frRef)
{
return AreSameFrame( frRef, GLOB_FRM) ;
}
+5 -6
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkGdbConst.h Data : 17.06.14 Versione : 1.5f5
// File : EgkGdbConst.h Data : 17.06.14 Versione : 1.5f5
// Contenuto : Costanti generali per DB geometrico.
//
//
@@ -83,8 +83,7 @@ const std::string GDB_SI_LIST = "!LST" ; // Vettore Id entit
const std::string GDB_SI_COPY = "!COP" ; // Id entità
const std::string GDB_SI_MGRPONLY = "!MGO" ; // Id entità
const std::string GDB_SI_DRAWMODE = "!DRM" ; // Flag
const std::string GDB_SI_DUPSOU = "!DSOU" ; // Duplo Id entità originale
const std::string GDB_SI_DUPLIST = "!DLST" ; // Duplo Vettore Id entità duplicate
const std::string GDB_SI_DUPMODIF = "!DMOD" ; // Flag di sorgente per duplo modificato
const std::string GDB_SI_DUPLOCKED = "!DLOK" ; // Flag di duplo bloccato (da non aggiornare seguendo originale)
const std::string GDB_SI_DUPTOUPDATE = "!DTUP" ; // Flag di duplo da aggiornare quando sbloccato
const std::string GDB_SI_DUPSOU = "!DSOU" ; // Id entità
const std::string GDB_SI_DUPLIST = "!DLST" ; // Vettore Id entità
const std::string GDB_SI_DUPMODIF = "!DMOD" ; // Flag
+2 -2
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkGdbExecutor.h Data : 25.11.13 Versione : 1.3a1
// File : EgkGdbExecutor.h Data : 25.11.13 Versione : 1.3a1
// Contenuto : Dichiarazione della interfaccia IGdbExecutor.
//
//
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGnCmdExecutor.h"
#include "/EgtDev/Include/EgnCmdExecutor.h"
class IGeomDB ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGkGdbFunct.h Data : 13.03.14 Versione : 1.5c6
// File : EgkGdbFunct.h Data : 13.03.14 Versione : 1.5c6
// Contenuto : Funzioni generali per DB geometrico.
//
//
+4 -10
View File
@@ -1,14 +1,13 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGkGdbIterator.h Data : 09.07.23 Versione : 2.5g1
// File : EGkGdbIterator.h Data : 04.12.13 Versione : 1.4a3
// Contenuto : Dichiarazione della interfaccia IGdbIterator.
//
//
//
// Modifiche : 04.12.13 DS Creazione modulo.
// 29.01.23 DS Aggiunte GetAllInfo e CopyAllInfoFrom.
// 09.07.23 DS Aggiunte SetStipple e GetStipple.
//
//
//----------------------------------------------------------------------------
@@ -143,11 +142,6 @@ class __declspec( novtable) IGdbIterator
virtual bool GetInfo( const std::string& sKey, STRVECTOR& vsInfo) const = 0 ;
virtual bool ExistsInfo( const std::string& sKey) const = 0 ;
virtual bool RemoveInfo( const std::string& sKey) = 0 ;
virtual bool GetAllInfo( STRVECTOR& vsInfo) const = 0 ;
virtual bool CopyAllInfoFrom( const IGdbIterator& iIter) = 0 ;
// Stipple
virtual bool SetStipple( int nFactor, int nPattern) = 0 ;
virtual bool GetStipple( int& nFactor, int& nPattern) const = 0 ;
// TextureData
virtual bool SetTextureName( const std::string& sTxrName) = 0 ;
virtual bool SetTextureFrame( const Frame3d& frTxrRef) = 0 ;
@@ -162,4 +156,4 @@ class __declspec( novtable) IGdbIterator
} ;
//-----------------------------------------------------------------------------
EGK_EXPORT IGdbIterator* CreateGdbIterator( IGeomDB* pGDB = nullptr) ;
EGK_EXPORT IGdbIterator* CreateGdbIterator( IGeomDB* pGDB = nullptr) ;
+7 -19
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2019
//----------------------------------------------------------------------------
// File : EGkGeoCollection.h Data : 05.11.19 Versione : 2.1k1
// File : EgkGeoCollection.h Data : 05.11.19 Versione : 2.1k1
// Contenuto : Raccolte di oggetti geometrici.
//
//
@@ -23,24 +23,18 @@
typedef std::vector<Point3d> PNTVECTOR ; // vettore di punti
typedef std::list<Point3d> PNTLIST ; // lista di punti
typedef std::vector<PNTVECTOR> PNTMATRIX ; // matrice di punti
//----------------------------------------------------------------------------
// Raccolte di coppie Point3d,int
typedef std::pair<Point3d,int> POINTI ; // coppia punto, intero
typedef std::vector<POINTI> PNTIVECTOR ; // vettore di coppie punto, intero
typedef std::list<POINTI> PNTILIST ; // lista di coppie punto, intero
//----------------------------------------------------------------------------
// Raccolte di coppie Point3d,dU
typedef std::pair<Point3d,double> POINTU ; // coppia punto, parametro (o altro)
typedef std::vector<POINTU> PNTUVECTOR ; // vettore di coppie punto, parametro
typedef std::list<POINTU> PNTULIST ; // lista di coppie punto, parametro
typedef std::pair<Point3d,double> POINTU ; // coppia punto, parametro (o altro)
typedef std::vector<POINTU> PNTUVECTOR ; // vettore di coppie punto, parametro
typedef std::list<POINTU> PNTULIST ; // lista di coppie punto, parametro
//----------------------------------------------------------------------------
// Raccolte di coppie Point3d,Point3d
typedef std::pair<Point3d,Point3d> BIPOINT ; // coppia punto1, punto2
typedef std::vector<BIPOINT> BIPNTVECTOR ; // vettore di coppie punto1, punto2
typedef std::list<BIPOINT> BIPNTLIST ; // lista di coppie punto1, punto2
typedef std::pair<Point3d,Point3d> BIPOINT ; // coppia punto1, punto2
typedef std::vector<BIPOINT> BIPNTVECTOR ; // vettore di coppie punto1, punto2
typedef std::list<BIPOINT> BIPNTLIST ; // lista di coppie punto1, punto2
//----------------------------------------------------------------------------
// Raccolte di Punti di curva con loro geometria differenziale
@@ -57,9 +51,3 @@ typedef std::list<Vector3d> VCT3DLIST ; // lista di vettori 3d
typedef std::vector<BBox3d> BOXVECTOR ; // vettore di bounding box 3d
typedef std::list<BBox3d> BOXLIST ; // lista di bounding box 3d
typedef std::vector<std::pair<BBox3d,int>> BOXIVECTOR ; // vettore di bounding box 3d e Id
//----------------------------------------------------------------------------
// Raccolte di coppie Point3d,Vector3d
typedef std::pair<Point3d,Vector3d> PNTVECT ; // coppia punto, vettore
typedef std::vector<PNTVECT> PNTVECTVECTOR ; // vettore di coppie punto, vettore
typedef std::list<PNTVECT> PNTVECTLIST ; // lista di coppie punto, vettore
+1 -4
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2019
//----------------------------------------------------------------------------
// File : EGkGeoConst.h Data : 23.11.19 Versione : 2.1k5
// File : EgkGeoConst.h Data : 23.11.19 Versione : 2.1k5
// Contenuto : Costanti generali per calcoli geometrici.
//
//
@@ -33,9 +33,6 @@ const double SQ_EPS_ZERO = EPS_ZERO * EPS_ZERO ;
const double INFINITO = 1e10 ;
const double SQ_INFINITO = INFINITO * INFINITO ;
// coefficiente componente di vettore largamente predominante
const double KV_BIG = 1e5 ;
// conversione da gradi a radianti e viceversa
const double PIGRECO = 3.14159265358979323846 ;
const double DEGTORAD = PIGRECO / 180. ;
-2
View File
@@ -56,8 +56,6 @@ class __declspec( novtable) IGeoObj
virtual const IObjGraphics* GetObjGraphics( void) const = 0 ;
virtual void SetTempProp( int nProp, int nPropInd = 0) = 0 ;
virtual int GetTempProp( int nPropInd = 0) const = 0 ;
virtual void SetTempParam( double dParam, int nParamInd = 0) = 0 ;
virtual double GetTempParam( int nParamInd = 0) const = 0 ;
} ;
//-----------------------------------------------------------------------------
+2 -6
View File
@@ -1,13 +1,12 @@
//----------------------------------------------------------------------------
// EgalTech 2017-2022
// EgalTech 2017-2017
//----------------------------------------------------------------------------
// File : EGkGeoObjSave.h Data : 25.04.22 Versione : 2.4d4
// File : EGkGeoObjSave.h Data : 30.10.17 Versione : 1.8j5
// Contenuto : Funzione per salvare su file un Oggetto Geometrico.
//
//
//
// Modifiche : 30.10.17 DS Creazione modulo.
// 25.04.22 DS Aggiunti controlli.
//
//----------------------------------------------------------------------------
@@ -21,9 +20,6 @@
bool
SaveGeoObj( IGeoObj* pGObj, const std::string& sFile, int nFlag = GDB_SV_BIN)
{
// verifico validità oggetto
if ( pGObj == nullptr || ! pGObj->IsValid())
return false ;
// creo GeomDB temporaneo
PtrOwner<IGeomDB> pGeomDB( CreateGeomDB()) ;
if ( IsNull( pGeomDB))
+2 -9
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkGeomDB.h Data : 09.07.23 Versione : 2.5g1
// File : EGkGeomDB.h Data : 03.12.14 Versione : 1.5k1
// Contenuto : Dichiarazione della interfaccia IGeomDB.
//
//
@@ -11,8 +11,6 @@
// 21.05.14 DS Agg. GotoFirst/Next/Last/Prev.
// 30.05.14 DS Agg. metodi di Shear.
// 03.12.14 DS Aggiunta gestione riferimento di griglia.
// 29.01.23 DS Aggiunta GetAllInfo.
// 09.07.23 DS Aggiunte DumpStipple, SetStipple e GetStipple.
//
//----------------------------------------------------------------------------
@@ -178,12 +176,7 @@ class __declspec( novtable) IGeomDB
virtual bool GetInfo( int nId, const std::string& sKey, STRVECTOR& vsInfo) const = 0 ;
virtual bool ExistsInfo( int nId, const std::string& sKey) const = 0 ;
virtual bool RemoveInfo( int nId, const std::string& sKey) = 0 ;
virtual bool GetAllInfo( int nId, STRVECTOR& vsInfo) const = 0 ;
virtual bool CopyAllInfoFrom( int nId, int nSouId) = 0 ;
// Stipple (significativo solo per curve)
virtual bool DumpStipple( int nId, std::string& sOut, bool bMM = true, const char* szNewLine = "\n") const = 0 ;
virtual bool SetStipple( int nId, int nFactor, int nPattern) = 0 ;
virtual bool GetStipple( int nId, int& nFactor, int& nPattern) const = 0 ;
// TextureData
virtual bool DumpTextureData( int nId, std::string& sOut, bool bMM = true, const char* szNewLine = "\n") const = 0 ;
virtual bool SetTextureName( int nId, const std::string& sTxrName) = 0 ;
-76
View File
@@ -1,76 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2018
//----------------------------------------------------------------------------
// File : EGkHashGrids1d.h Data : 02.05.21 Versione : 2.4e1
// Contenuto : Dichiarazione della classe HashGrids1d.
//
//
//
// Modifiche : 04.07.15 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "EgtDev/Include/EGkBBox3d.h"
#include "EgtDev/Include/EgtNumCollection.h"
#include <unordered_map>
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
class HashGrids1d
{
public :
EGK_EXPORT HashGrids1d( void) ;
EGK_EXPORT ~HashGrids1d( void) ;
EGK_EXPORT void SetActivationGrid( bool bActivate) ;
EGK_EXPORT bool Add( int nObjId, const BBox3d& box) ;
EGK_EXPORT bool Modify( int nObjId, const BBox3d& box) ;
EGK_EXPORT bool Remove( int nObjId) ;
EGK_EXPORT bool Update( void) ;
EGK_EXPORT bool Find( const BBox3d& b3Test, INTVECTOR& vnIds) const ;
EGK_EXPORT void Clear( void) ;
friend class HashGrid1d ;
private :
struct ObjData {
int nId ;
BBox3d box ;
HashGrid1d* pHGrid ;
size_t nHash ;
size_t nCellId ;
ObjData( void)
: nId( -1), box(), pHGrid( nullptr), nHash( 0), nCellId( 0) {}
ObjData( int nI, const BBox3d& bb, HashGrid1d* pHG, size_t nH, size_t nCI)
: nId( nI), box( bb), pHGrid( pHG), nHash( nH), nCellId( nCI) {}
} ;
typedef std::list<ObjData> ObjList ;
typedef std::vector<ObjData*> PtrObjVector ;
typedef std::unordered_map<int,ObjData*> IntPObjUmap ;
private :
typedef std::list<HashGrid1d*> GridList ; // Tipo per lista di hash grid
private :
void addGrid( ObjData& obj) ;
void addList( ObjData& obj) ;
private :
ObjList m_ObjsList ; // Lista degli oggetti
IntPObjUmap m_ObjsMap ; // Map da Id a PtrObj
PtrObjVector m_objsToAdd ; // Vettore di puntatori agli oggetti da inserire
PtrObjVector m_nonGridObjs ; // Vettore di puntatori agli oggetti non assegnati alle griglie (per dimensioni o perchè pochi)
GridList m_GridList ; // Lista delle griglie di dimensione fissa ( in ordine crescente di dimensione di cella)
bool m_bActivate ; // Flag che abilita l'attivazione delle griglie
bool m_bGridActive ; // Flag di attivazione delle griglie
BBox3d m_b3Objs ; // Box totale di tutti gli oggetti inseriti
} ;
-16
View File
@@ -14,7 +14,6 @@
#pragma once
#include "/EgtDev/Include/EGkSurfTriMesh.h"
#include "/EgtDev/Include/EGkHashGrids1d.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
@@ -27,18 +26,3 @@
//-----------------------------------------------------------------------------
EGK_EXPORT bool IntersPlaneSurfTm( const Plane3d& plPlane, const ISurfTriMesh& Stm,
PNTVECTOR& vPnt, BIPNTVECTOR& vBpt, TRIA3DVECTOR& vTria) ;
//-----------------------------------------------------------------------------
class IntersParPlanesSurfTm
{
public :
EGK_EXPORT IntersParPlanesSurfTm( const Frame3d& frPlanes, const ISurfTriMesh& Stm) ;
EGK_EXPORT bool GetInters( double dDist, PNTVECTOR& vPnt, BIPNTVECTOR& vBpt, TRIA3DVECTOR& vTria) const ;
private :
bool m_bOk ;
const Frame3d m_frPlanes ;
const ISurfTriMesh* m_pSTm ;
HashGrids1d m_HGrids ;
} ;
+1 -1
View File
@@ -20,7 +20,7 @@
#include "/EgtDev/Include/EGkColor.h"
#include "/EgtDev/Include/EGkGeoCollection.h"
#include "/EgtDev/Include/EGkSelection.h"
#include "/EgtDev/Include/EGnLuaAux.h"
#include "/EgtDev/Include/EgnLuaAux.h"
//----------------------------------------------------------------------------
inline bool
-27
View File
@@ -1,27 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2022-2022
//----------------------------------------------------------------------------
// File : MedialAxis.h Data : 22.08.22 Versione : 2.4h2
// Contenuto : Dichiarazione funzione calcolo MedialAxis principale.
//
//
//
// Modifiche : 22.08.22 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkCurve.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
EGK_EXPORT bool CurveSimpleMedialAxis( const ICurve* pCrv, PolyLine& PL) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2019
//----------------------------------------------------------------------------
// File : EGkObjGraphics.h Data : 08/03/19 Versione : 2.1c1
// File : EgkObjGraphics.h Data : 08/03/19 Versione : 2.1c1
// Contenuto : Dichiarazione della interfaccia IObjGraphics.
//
//
-5
View File
@@ -26,8 +26,6 @@
class OffsetCurve
{
public :
EGK_EXPORT OffsetCurve(): m_dLinTol( 10 * EPS_SMALL) {} ;
EGK_EXPORT OffsetCurve( double dLinTol) : m_dLinTol( dLinTol) {} ;
EGK_EXPORT ~OffsetCurve( void) ;
public :
@@ -37,10 +35,7 @@ class OffsetCurve
EGK_EXPORT ICurve* GetCurve( void) ;
EGK_EXPORT ICurve* GetLongerCurve( void) ;
EGK_EXPORT ICurve* GetShorterCurve( void) ;
EGK_EXPORT double GetLinTol( void) const { return m_dLinTol ; }
EGK_EXPORT void SetLinTol( double dTol) { m_dLinTol = dTol ; }
private :
ICURVEPLIST m_CrvLst ;
double m_dLinTol ;
} ;
-10
View File
@@ -38,16 +38,6 @@ class Plane3d
m_dDist = ( ptP - ORIG) * m_vtN ;
return true ;
}
bool Set( const Point3d& ptP1, const Point3d& ptP2, const Point3d& ptP3)
{ if ( AreSamePointApprox( ptP1, ptP2) ||
AreSamePointApprox( ptP2, ptP3) ||
AreSamePointApprox( ptP3, ptP1)) {
m_vtN = V_NULL ;
return false ;
}
Vector3d vtN = ( ptP2 - ptP1) ^ ( ptP3 - ptP2) ;
return Set( ptP1, vtN) ;
}
void Reset( void)
{ m_vtN = V_NULL ;
m_dDist = 0 ;
+17 -56
View File
@@ -1,13 +1,12 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkPoint3d.h Data : 23.08.23 Versione : 2.5h2
// File : EGkPoint3d.h Data : 30.05.14 Versione : 1.5e10
// Contenuto : Dichiarazione della classe Punto 3d.
//
//
//
// Modifiche : 30.12.12 DS Creazione modulo.
// 23.08.23 DS Aggiunto P_INVALID.
//
//
//----------------------------------------------------------------------------
@@ -43,9 +42,6 @@ class EGK_EXPORT Point3d
void Set( double dX, double dY, double dZ) { x = dX ; y = dY ; z = dZ ;}
public :
//! Verifica la validità delle coordinate del punto
bool IsValid( void) const
{ return ( std::isfinite( x) && std::isfinite( y) && std::isfinite( z)) ; }
//! Verifica se il punto è quasi l'origine
bool IsSmall( void) const
{ return ( ( x * x + y * y + z * z) < SQ_EPS_SMALL) ; }
@@ -54,19 +50,19 @@ class EGK_EXPORT Point3d
{ return ( ( x * x + y * y + z * z) < SQ_EPS_ZERO) ; }
//! Somma sul posto con un vettore
Point3d& operator +=( const Vector3d& vtV)
{ x += vtV.x ; y += vtV.y ; z += vtV.z ; return *this ; }
{ this->x += vtV.x ; this->y += vtV.y ; this->z += vtV.z ; return *this ; }
//! Sottrazione sul posto con un vettore
Point3d& operator -=( const Vector3d& vtV)
{ x -= vtV.x ; y -= vtV.y ; z -= vtV.z ; return *this ; }
{ this->x -= vtV.x ; this->y -= vtV.y ; this->z -= vtV.z ; return *this ; }
//! Somma sul posto con un altro punto (valida solo se equivalente ad una combinazione baricentrica)
Point3d& operator +=( const Point3d& ptP)
{ x += ptP.x ; y += ptP.y ; z += ptP.z ; return *this ; }
{ this->x += ptP.x ; this->y += ptP.y ; this->z += ptP.z ; return *this ; }
//! Moltiplicazione sul posto con un numero
Point3d& operator *=( double dMul)
{ x *= dMul ; y *= dMul ; z *= dMul ; return *this ; }
{ this->x *= dMul ; this->y *= dMul ; this->z *= dMul ; return *this ; }
//! Divisione sul posto con un numero
Point3d& operator /=( double dDiv)
{ double dMul = 1 / dDiv ; x *= dMul ; y *= dMul ; z *= dMul ; return *this ; }
{ double dMul = 1 / dDiv ; this->x *= dMul ; this->y *= dMul ; this->z *= dMul ; return *this ; }
//! Traslazione dato il vettore di movimento
void Translate( const Vector3d& vtMove) ;
//! Rotazione attorno ad un asse per un punto, dato l'angolo in gradi
@@ -100,15 +96,13 @@ class EGK_EXPORT Point3d
//----------------------------------------------------------------------------
// Punti notevoli
//----------------------------------------------------------------------------
//! Punto non valido
const Point3d P_INVALID( NAN, NAN, NAN) ;
//! Punto origine
const Point3d ORIG( 0, 0, 0) ;
//----------------------------------------------------------------------------
//! Somma di due punti (valida solo se equivalente ad una combinazione baricentrica)
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator+( const Point3d& ptP1, const Point3d& ptP2)
{
return Point3d( ptP1.x + ptP2.x, ptP1.y + ptP2.y, ptP1.z + ptP2.z) ;
@@ -117,16 +111,16 @@ operator+( const Point3d& ptP1, const Point3d& ptP2)
//----------------------------------------------------------------------------
//! Somma di un punto e un vettore
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator+( const Point3d& ptP1, const Vector3d& vtV2)
{
return Point3d( ptP1.x + vtV2.x, ptP1.y + vtV2.y, ptP1.z + vtV2.z) ;
}
//----------------------------------------------------------------------------
//! Opposto di un punto, genera un vettore
//! Opposto di un punto
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator-( const Point3d& ptP)
{
return Vector3d( - ptP.x, - ptP.y, - ptP.z) ;
@@ -135,7 +129,7 @@ operator-( const Point3d& ptP)
//----------------------------------------------------------------------------
//! Differenza di due punti, genera un vettore
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator-( const Point3d& ptP1, const Point3d& ptP2)
{
return Vector3d( ptP1.x - ptP2.x, ptP1.y - ptP2.y, ptP1.z - ptP2.z) ;
@@ -144,7 +138,7 @@ operator-( const Point3d& ptP1, const Point3d& ptP2)
//----------------------------------------------------------------------------
//! Sottrazione di un punto e un vettore
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator-( const Point3d& ptP1, const Vector3d& vtV2)
{
return Point3d( ptP1.x - vtV2.x, ptP1.y - vtV2.y, ptP1.z - vtV2.z) ;
@@ -153,7 +147,7 @@ operator-( const Point3d& ptP1, const Vector3d& vtV2)
//----------------------------------------------------------------------------
//! Prodotto con uno scalare
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator*( const Point3d& ptP, double dMul)
{
return Point3d( ptP.x * dMul, ptP.y * dMul, ptP.z * dMul) ;
@@ -162,7 +156,7 @@ operator*( const Point3d& ptP, double dMul)
//----------------------------------------------------------------------------
//! Prodotto di uno scalare con un punto
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator*( double dMul, const Point3d& ptP)
{
return Point3d( ptP.x * dMul, ptP.y * dMul, ptP.z * dMul) ;
@@ -171,7 +165,7 @@ operator*( double dMul, const Point3d& ptP)
//----------------------------------------------------------------------------
//! Divisione per uno scalare
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
operator/( const Point3d& ptP, double dDiv)
{
double dMul ;
@@ -183,7 +177,7 @@ operator/( const Point3d& ptP, double dDiv)
//----------------------------------------------------------------------------
//! Somma mediata di due punti (baricentrica)
//----------------------------------------------------------------------------
inline const Point3d
inline Point3d
Media( const Point3d& ptP1, const Point3d& ptP2, double dCoeff = 0.5)
{
return Point3d( ( 1 - dCoeff) * ptP1.x + dCoeff * ptP2.x,
@@ -370,36 +364,3 @@ AreSamePointXYExact( const Point3d& ptP1, const Point3d& ptP2)
{
return ( SqDistXY( ptP1, ptP2) < SQ_EPS_ZERO) ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in locale del punto passato
//----------------------------------------------------------------------------
inline const Point3d
GetToLoc( const Point3d& ptP, const Frame3d& frRef)
{
Point3d ptQ = ptP ;
ptQ.ToLoc( frRef) ;
return ptQ ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in globale del punto passato
//----------------------------------------------------------------------------
inline const Point3d
GetToGlob( const Point3d& ptP, const Frame3d& frRef)
{
Point3d ptQ = ptP ;
ptQ.ToGlob( frRef) ;
return ptQ ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia dal primo al secondo riferimento del punto passato
//----------------------------------------------------------------------------
inline const Point3d
GetLocToLoc( const Point3d& ptP, const Frame3d& frOri, const Frame3d& frDest)
{
Point3d ptQ = ptP ;
ptQ.LocToLoc( frOri, frDest) ;
return ptQ ;
}
+1 -1
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkBBox3d.h"
#include "/EgtDev/Include/EgkBBox3d.h"
#include "/EgtDev/Include/EgtNumCollection.h"
#include <unordered_map>
+10 -19
View File
@@ -116,11 +116,6 @@ class PolyLine
EGK_EXPORT bool GetConvexHullXY( PNTVECTOR& vConvHull) const ;
EGK_EXPORT bool GetMinAreaRectangleXY( Point3d& ptCen, Vector3d& vtAx, double& dLen, double& dHeight) const ;
EGK_EXPORT bool Trim( const Plane3d& plPlane, bool bInVsOut = true) ;
EGK_EXPORT void SetTempProp( int nProp, int nPropInd = 0)
{ if ( nPropInd >= 0 && nPropInd < 2)
m_nTempProp[nPropInd] = nProp ; }
EGK_EXPORT int GetTempProp( int nPropInd = 0) const
{ return (( nPropInd >= 0 && nPropInd < 2) ? m_nTempProp[nPropInd] : 0) ; }
private :
bool MyChangeStart( int nPos) ;
@@ -128,23 +123,19 @@ class PolyLine
bool MyMakeConvex( const Vector3d& vtN, bool bLeftSide) ;
private :
int m_nRejected ; // numero punti rifiutati perchè coincidenti
int m_nTempProp[2] ; // vettore proprietà temporanee
PNTULIST m_lUPoints ; // lista dei punti
mutable PNTULIST::const_iterator m_iter ; // iteratore corrente
int m_nRejected ;
PNTULIST m_lUPoints ;
mutable PNTULIST::const_iterator m_iter ;
} ;
//----------------------------------------------------------------------------
// Raccolte di PolyLine
typedef std::vector<PolyLine> POLYLINEVECTOR ; // vettore di PolyLine
typedef std::list<PolyLine> POLYLINELIST ; // lista di PolyLine
typedef std::vector<POLYLINEVECTOR> POLYLINEMATRIX ; // matrice di PolyLine
typedef std::vector<PolyLine> POLYLINEVECTOR ; // vettore di PolyLine
typedef std::list<PolyLine> POLYLINELIST ; // lista di PolyLine
//----------------------------------------------------------------------------
EGK_EXPORT bool DistPointPolyLine( const Point3d& ptP, const PolyLine& plPoly, double& dDist) ;
EGK_EXPORT bool DistPointPolyLine( const Point3d& ptP, const PolyLine& plPoly, double& dDist, double& dMinDistPar) ;
EGK_EXPORT bool IsPointInsidePolyLine( const Point3d& ptP, const PolyLine& plPoly, double dToler) ;
EGK_EXPORT bool GetPointParamOnPolyLine( const Point3d& ptP, const PolyLine& plPoly, double dToler, double& dPar) ;
EGK_EXPORT bool ChangePolyLineStart( PolyLine& plPoly, const Point3d& ptNewStart, double dToler) ;
EGK_EXPORT bool SplitPolyLineAtPoint( const PolyLine& plPoly, const Point3d& ptP, double dToler, PolyLine& plPoly1, PolyLine& plPoly2) ;
EGK_EXPORT bool AssociatePolyLinesMinDistPoints( const PolyLine& PL1, const PolyLine& PL2, PNTIVECTOR& vPnt1, PNTIVECTOR& vPnt2, bool& bCommonInternalPoints) ;
bool DistPointPolyLine( const Point3d& ptP, const PolyLine& plPoly, double& dDist) ;
bool IsPointInsidePolyLine( const Point3d& ptP, const PolyLine& plPoly, double dToler) ;
bool GetPointParamOnPolyLine( const Point3d& ptP, const PolyLine& plPoly, double dToler, double& dPar) ;
bool ChangePolyLineStart( PolyLine& plPoly, const Point3d& ptNewStart, double dToler) ;
bool SplitPolyLineAtPoint( const PolyLine& plPoly, const Point3d& ptP, double dToler, PolyLine& plPoly1, PolyLine& plPoly2) ;
+3 -3
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2023
// EgalTech 2015-2020
//----------------------------------------------------------------------------
// File : EGkPolygon3d.h Data : 17.12.23 Versione : 2.5l3
// File : Polygon3d.h Data : 02.10.20 Versione : 2.2j1
// Contenuto : Dichiarazione della classe Polygon3d (poligono nello spazio).
//
//
@@ -58,7 +58,7 @@ class Polygon3d
EGK_EXPORT bool ToGlob( const Frame3d& frRef) ;
EGK_EXPORT bool ToLoc( const Frame3d& frRef) ;
EGK_EXPORT bool LocToLoc( const Frame3d& frOri, const Frame3d& frDest) ;
EGK_EXPORT bool GetLocalBBox( BBox3d& b3Loc) const ;
EGK_EXPORT bool IsValid( void) const
{ return ! m_Plane.GetVersN().IsSmall() ; }
EGK_EXPORT const Plane3d& GetPlane( void) const
-32
View File
@@ -1,32 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGkPolygonElevation.h Data : 02.10.20 Versione : 2.2j1
// Contenuto : Dichiarazione della classe Polygon3d (poligono nello spazio).
//
//
//
// Modifiche : 30.08.15 DS Creazione modulo.
// 19.06.19 DS Aggiunta GetVertices.
// 23.07.19 DS Aggiunte Offset e Invert.
// 02.10.20 DS A FromPlaneTrimmedWithBox aggiunto parametro dToler.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkPolygon3d.h"
#include "/EgtDev/Include/EGkSurfTriMesh.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
EGK_EXPORT bool PolygonElevationInBBox( const Polygon3d& pgFacet, const BBox3d& b3Box, bool bAcceptOutFacet, double& dElev) ;
EGK_EXPORT bool PolygonElevationInClosedSurfTm( const Polygon3d& pgFacet, const ISurfTriMesh& CldStm, bool bAcceptOutFacet, double& dElev) ;
-43
View File
@@ -1,43 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGkProjectCurveSurfTm.h Data : 31.08.23 Versione : 2.5h3
// Contenuto : Dichiarazione funzioni proiezione curve su superficie Trimesh.
//
//
//
// Modifiche : 31.08.23 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkCurve.h"
#include "/EgtDev/Include/EGkSurfTriMesh.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
// Definizione di Punto 5assi e sue raccolte
struct Point5ax {
Point3d ptP ;
Vector3d vtDir ;
double dPar ;
int nFlag ;
Point5ax( void) : ptP(), vtDir(), dPar(), nFlag() {} ;
Point5ax( const Point3d& ptBase, const Vector3d& vtTool, double dU, int nData)
: ptP( ptBase), vtDir( vtTool), dPar( dU), nFlag( nData) {} ;
} ;
typedef std::vector<Point5ax> PNT5AXVECTOR ; // vettore di Punti 5assi
//----------------------------------------------------------------------------
// Proiezione di una curva su una superficie TriMesh lungo la direzione data.
EGK_EXPORT bool ProjectCurveOnSurfTm( const ICurve& crCrv, const ISurfTriMesh& tmSurf, const Vector3d& vtDir, double dLinTol,
PNT5AXVECTOR& vPt5ax) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkSelection.h Data : 11.06.15 Versione : 1.6f2
// File : EgkSelection.h Data : 11.06.15 Versione : 1.6f2
// Contenuto : Strutture e raccolte per indici di selezione,
// con funzioni di conversione da e verso stringhe.
//
+1 -1
View File
@@ -30,7 +30,7 @@ EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionRectangle( double dWidth, double dL
EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionStadium( double dWidth, double dLen) ;
EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionDisk( double dRadius) ;
EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionFromFatCurve( ICurve* pCrv, double dRadius,
bool bSquareEnds, bool bSquareMids, double dOffsLinTol = 10 * EPS_SMALL) ;
bool bSquareEnds, bool bSquareMids) ;
// NB : la curva ingrassata non deve autointersecarsi
EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionFromTriangle( const Triangle3d& Tria) ;
EGK_EXPORT ISurfFlatRegion* GetSurfFlatRegionFromPolyLine( const PolyLine& ContourPolyLine) ;
+1 -6
View File
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGkCurve.h"
#include "/EgtDev/Include/EgkCurve.h"
#include "/EgtDev/Include/EGkSurfTriMesh.h"
//----------------------- Macro per import/export ----------------------------
@@ -24,9 +24,6 @@
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
enum RS_CAP { RSCAP_NONE = 0, RSCAP_FLAT = 1, RSCAP_ROUND = 2, RSCAP_BEVEL = 3} ;
//----------------------------------------------------------------------------
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshByFlatContour( const ICurve* pCurve, double dLinTol = 10 * EPS_SMALL) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshByRegion( const CICURVEPVECTOR& vpCurve, double dLinTol = 10 * EPS_SMALL) ;
@@ -38,8 +35,6 @@ EGK_EXPORT ISurfTriMesh* GetSurfTriMeshByRevolve( const ICurve* pCurve, const Po
const Vector3d& vtAx, bool bCapEnds, double dLinTol = 10 * EPS_SMALL) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshByScrewing( const ICurve* pCurve, const Point3d& ptAx, const Vector3d& vtAx,
double dAngRotDeg, double dMove, bool bCapEnds, double dLinTol = 10 * EPS_SMALL) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshRectSwept( double dDimH, double dDimV, double dBevelH, double dBevelV,
const ICurve* pGuide, int nCapType, double dLinTol) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshSwept( const ICurve* pSect, const ICurve* pGuide, bool bCapEnds, double dLinTol = 10 * EPS_SMALL) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshRuled( const Point3d& ptP, const ICurve* pCurve, double dLinTol = 10 * EPS_SMALL) ;
EGK_EXPORT ISurfTriMesh* GetSurfTriMeshRuled( const ICurve* pCurve1, const ICurve* pCurve2, int nType, double dLinTol = 10 * EPS_SMALL) ;
+4 -6
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2023
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGkStmFromTriangleSoup.h Data : 07.05.23 Versione : 2.5e2
// File : EGkStmFromTriangleSoup.h Data : 19.05.14 Versione : 1.5e7
// Contenuto : Dichiarazione della classe StmFromTriangleSoup.
//
//
@@ -35,14 +35,12 @@ class StmFromTriangleSoup
EGK_EXPORT ~StmFromTriangleSoup( void) ;
EGK_EXPORT bool Start( int nBuckets = GRID_STD_BUCKETS) ;
EGK_EXPORT bool AddTriangle( const Triangle3d& Tria) ;
EGK_EXPORT bool AddTriangle( const Point3d& ptP0, const Point3d& ptP1, const Point3d& ptP2,
double dU0 = -1, double dV0 = -1, double dU1 = -1, double dV1 = -1, double dU2 = -1, double dV2 = -1) ;
EGK_EXPORT bool AddSurfTriMesh( const ISurfTriMesh& stmSource) ;
EGK_EXPORT bool AddTriangle( const Point3d& ptP0, const Point3d& ptP1, const Point3d& ptP2) ;
EGK_EXPORT bool End( void) ;
EGK_EXPORT ISurfTriMesh* GetSurf( void) ;
private :
inline int AddVertex( const Point3d& ptP, double dU = -1, double dV = -1) ;
inline int AddVertex( const Point3d& ptP) ;
private :
ISurfTriMesh* m_pSTM ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGkStringUtils3d.h Data : 10.03.14 Versione : 1.5c3
// File : EgkStringUtils3d.h Data : 10.03.14 Versione : 1.5c3
// Contenuto : Dichiarazione delle funzioni di utilità 3d per le stringhe.
//
//
-29
View File
@@ -1,29 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGkSubtractProjectedFacesOnStmFace.h Data : 26.09.23 Versione : 2.5j1
// Contenuto : Dichiarazione della funzione per proiettare facce di TriMesh su una superficie di TriMesh.
//
//
//
// Modifiche : 26.09.23 RE Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkSurfTriMesh.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
EGK_EXPORT bool SubtractProjectedFacesOnStmFace( const ISurfTriMesh& Stm, int nFaceInd, ISURFTMPOVECTOR& vStmOthers,
bool bOCFlag, bool& bExistProjection, ISurfTriMesh*& pStmRes,
int& nNewFaceNbr) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2019
//----------------------------------------------------------------------------
// File : EGkSurf.h Data : 06.06.19 Versione : 2.1f1
// File : EgkSurf.h Data : 06.06.19 Versione : 2.1f1
// Contenuto : Dichiarazione della interfaccia ISurf.
//
//
-61
View File
@@ -1,61 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGkSurfAux.h Data : 09.08.23 Versione :
// Contenuto : Dichiarazione funzioni ausiliarie per ISurf.
//
//
//
// Modifiche : 09.08.23 DB Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkCurveComposite.h"
#include "/EgtDev/Include/EGkSurf.h"
#include "/EgtDev/Include/EGkGeoCollection.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
//----------------------------------------------------------------------------
//! Struttura dati per superficie Nurbs
struct SNurbsSurfData
{
int nDegU ; // grado in U
int nDegV ; // grado in V
bool bRat ; // flag di superficie razionale (pesi non tutti unitari)
bool bPeriodicU ; // flag per segnalare vettore dei nodi periodico in U
bool bPeriodicV ; // flag per segnalare vettore dei nodi periodico in V
bool bClosedU ; // flag di superficie chiusa sul parametro U
bool bClosedV ; // flag di superficie chiusa sul parametro V
bool bClampedU ; // flag di superficie clamped sul parametro U
bool bClampedV ; // flag di superficie clamped sul parametro V
bool bExtraKnotes ; // flag per segnalare presenza di nodi extra all'inizio e fine (totale 2)
DBLVECTOR vU ; // vettore dei nodi in U
DBLVECTOR vV ; // vettore dei nodi in V
int nCPU ; // numero di punti di controllo in U
int nCPV ; // numero di punti di controllo in V
PNTVECTOR vCP ; // vettore dei punti di controllo
PNTMATRIX mCP ; // matrice dei punti di controllo
DBLMATRIX mW ; // matrice dei pesi
SNurbsSurfData( void) : nDegU( 0), nDegV( 0), bRat( false), bPeriodicU( false), bPeriodicV( false), bClosedU( false), bClosedV( false),
bClampedU( false), bClampedV( false), bExtraKnotes(false) {}
} ;
// N.B. : in caso la superficie sia razionale i punti di controllo sono in forma NON OMOGENEA [ x, y, z, w] ( dove la forma omogenea è [ w*x, w*y, w*z, w])
// tutte le operazioni richiedono la forma OMOGENEA, finite le quali posso riportarmi alla forma NON OMOGENEA
//----------------------------------------------------------------------------
//! Trasforma una superficie Nurbs standard in una nuova superficie di Bezier semplice o composta
EGK_EXPORT bool NurbsSurfaceCanonicalize( SNurbsSurfData& snData) ;
EGK_EXPORT ISurf* NurbsToBezierSurface( const SNurbsSurfData& snData) ;
-2
View File
@@ -37,7 +37,6 @@ class __declspec( novtable) ISurfBezier : public ISurf
virtual bool SetControlPoint( int nIndU, int nIndV, const Point3d& ptCtrl, double dW) = 0 ;
virtual bool SetControlPoint( int nInd, const Point3d& ptCtrl, double dW) = 0 ;
virtual bool SetTrimRegion( const ISurfFlatRegion& sfrTrimReg) = 0 ;
virtual ISurfFlatRegion* GetTrimRegion( void) const = 0 ;
virtual bool GetInfo( int& nDegU, int& nDegV, int& nSpanU, int& nSpanV, bool& bIsRat, bool& bTrimmed) const = 0 ;
virtual const Point3d& GetControlPoint( int nIndU, int nIndV, bool* pbOk) const = 0 ;
virtual const Point3d& GetControlPoint( int nInd, bool* pbOk) const = 0 ;
@@ -58,7 +57,6 @@ class __declspec( novtable) ISurfBezier : public ISurf
virtual bool GetControlCurveOnU( int nIndV, PolyLine& plCtrlU) const = 0 ;
virtual bool GetControlCurveOnV( int nIndU, PolyLine& plCtrlV) const = 0 ;
virtual const ISurfTriMesh* GetAuxSurf( void) const = 0 ;
virtual bool GetLeaves ( std::vector<std::tuple<int, Point3d, Point3d>>& vLeaves) const = 0 ;
} ;
//-----------------------------------------------------------------------------
+1 -7
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGkSurfFlatRegion.h Data : 05.08.15 Versione : 1.6h2
// File : EgkSurfFlatRegion.h Data : 05.08.15 Versione : 1.6h2
// Contenuto : Dichiarazione della interfaccia ISurfFlatRegion.
//
//
@@ -15,9 +15,7 @@
#include "/EgtDev/Include/EGkSurf.h"
#include "/EgtDev/Include/EGkIntersCurves.h"
#include "/EgtDev/Include/EgkCurveComposite.h"
#include "/EgtDev/Include/EgtPointerOwner.h"
#include "/EgtDev/Include/EGkVoronoi.h"
class ISurfTriMesh ;
@@ -37,7 +35,6 @@ class __declspec( novtable) ISurfFlatRegion : public ISurf
virtual bool Subtract( const ISurfFlatRegion& Other) = 0 ;
virtual bool Intersect( const ISurfFlatRegion& Other) = 0 ;
virtual bool Offset( double dDist, int nType) = 0 ;
virtual ISurfFlatRegion* CreateOffsetSurf( double dDist, int nType) const = 0 ;
virtual bool GetGrossArea( double& dArea) const = 0 ;
virtual const Point3d& GetPlanePoint( void) const = 0 ;
virtual const Vector3d& GetNormVersor( void) const = 0 ;
@@ -50,9 +47,6 @@ class __declspec( novtable) ISurfFlatRegion : public ISurf
virtual bool GetChunkCentroid( int nChunk, Point3d& ptCen) const ;
virtual bool GetCurveClassification( const ICurve& Crv, double dLenMin, CRVCVECTOR& ccClass) const = 0 ;
virtual int GetChunkSimpleClassification( int nChunk, const ISurfFlatRegion& Other, int nOthChunk) const ; // compare only outsides
virtual Voronoi* GetVoronoiObject( void) const = 0 ;
virtual bool CalcVoronoiDiagram( ICURVEPOVECTOR& vCrvs, int nBound = VORONOI_STD_BOUND) const = 0 ;
virtual bool CalcMedialAxis( ICURVEPOVECTOR& vCrvs, int nSide = Voronoi::WMAT_LEFT) const = 0 ;
} ;
//-----------------------------------------------------------------------------
+1 -1
View File
@@ -14,7 +14,7 @@
#pragma once
#include "/EgtDev/Include/EGkSurf.h"
#include "/EgtDEv/Include/EGkGeomDB.h"
#include "/EgtDEv/Include/EgkGeomDB.h"
//-----------------------------------------------------------------------------
class SurfLocal
+6 -17
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2023
// EgalTech 2014-2021
//----------------------------------------------------------------------------
// File : EGkSurfTriMesh.h Data : 10.12.23 Versione : 2.5l2
// File : EgkSurfTriMesh.h Data : 26.09.21 Versione : 2.3i2
// Contenuto : Dichiarazione della interfaccia ISurfTriMesh.
//
//
@@ -32,9 +32,8 @@ const double MAX_EDGE_LEN_STD = 5000.0 ;
class __declspec( novtable) ISurfTriMesh : public ISurf
{
public :
enum RuledType { RLT_ISOPAR = 0, // con parametrizzazione simile tra le due curve
RLT_MINDIST = 1, // con distanza minima tra le due curve
RLT_ISOPAR_SMOOTH = 2} ; // con parametrizzazione simile tra le due curve e lisciatura delle parti torte
enum RuledType { RLT_ISOPAR = 0, // con parametrizzazione simile tra le due curve
RLT_MINDIST = 1} ; // con distanza minima tra le due curve
public : // IGeoObj
ISurfTriMesh* Clone( void) const override = 0 ;
public :
@@ -43,8 +42,7 @@ class __declspec( novtable) ISurfTriMesh : public ISurf
virtual void SetLinearTolerance( double dLinTol) = 0 ;
virtual void SetBoundaryAngle( double dBoundaryAngDeg) = 0 ;
virtual void SetSmoothAngle( double dSmoothAngDeg) = 0 ;
virtual int AddVertex( const Point3d& ptVert, double dU = -1, double dV = -1) = 0 ;
virtual bool MoveVertex( int nInd, const Point3d& ptNewVert) = 0 ;
virtual int AddVertex( const Point3d& ptVert) = 0 ;
virtual int AddTriangle( const int nIdVert[3], int nTFlag = 0) = 0 ;
virtual bool RemoveTriangle( int nId) = 0 ;
virtual bool AdjustTopology( void) = 0 ;
@@ -59,7 +57,6 @@ class __declspec( novtable) ISurfTriMesh : public ISurf
double dAngRot, double dStepRot, double dMove) = 0 ;
virtual bool DoCompacting( double dTol = EPS_SMALL) = 0 ;
virtual bool DoSewing( const ISurfTriMesh& stmOther, const Frame3d& frOther = GLOB_FRM, double dTol = 2 * EPS_SMALL) = 0 ;
virtual bool IsEmpty( void) const = 0 ;
virtual int GetVertexCount( void) const = 0 ;
virtual int GetTriangleCount( void) const = 0 ;
virtual int GetTriangleCount( int nTFlag) const = 0 ;
@@ -68,7 +65,6 @@ class __declspec( novtable) ISurfTriMesh : public ISurf
virtual double GetLinearTolerance( void) const = 0 ;
virtual double GetSmoothAngle( void) const = 0 ;
virtual bool GetVertex( int nId, Point3d& ptP) const = 0 ;
virtual bool GetVertexParam( int nId, double& dU, double& dV) const = 0 ;
virtual int GetFirstVertex( Point3d& ptP) const = 0 ;
virtual int GetNextVertex( int nId, Point3d& ptP) const = 0 ;
virtual bool GetTriangle( int nId, int nIdVert[3]) const = 0 ;
@@ -84,14 +80,12 @@ class __declspec( novtable) ISurfTriMesh : public ISurf
virtual bool GetVertexSmoothNormal( int nV, int nT, Vector3d& vtN) const = 0 ;
virtual bool GetTriangleBoundaryEdges( int nId, TriFlags3d& TFlags) const = 0 ;
virtual bool GetTriangleSmoothNormals( int nId, TriNormals3d& TNrms) const = 0 ;
virtual ISurfTriMesh* CloneTriangle( int nTria) const = 0 ;
virtual bool GetLoops( POLYLINEVECTOR& vPL) const = 0 ;
virtual bool GetSilhouette( const Vector3d& vtDir, double dTol, POLYLINEVECTOR& vPL, bool bAllTria = false) const = 0 ;
virtual bool GetSilhouette( const Vector3d& vtDir, double dTol, POLYLINEVECTOR& vPL) const = 0 ;
virtual int GetFacetCount( void) const = 0 ;
virtual int GetFacetSize( void) const = 0 ;
virtual int GetFacetFromTria( int nT) const = 0 ;
virtual bool GetAllTriaInFacet( int nF, INTVECTOR& vT) const = 0 ;
virtual bool GetAllVertInFacet( int nF, INTVECTOR& vVert) const = 0 ;
virtual bool GetFacetLoops( int nF, POLYLINEVECTOR& vPL) const = 0 ;
virtual bool GetFacetAdjacencies( int nF, INTMATRIX& vAdj) const = 0 ;
virtual bool GetFacetNearestEndPoint( int nF, const Point3d& ptNear, Point3d& ptEnd, Vector3d& vtN) const = 0 ;
@@ -105,11 +99,6 @@ class __declspec( novtable) ISurfTriMesh : public ISurf
virtual bool SwapFacets( int nF1, int nF2) = 0 ;
virtual bool GetFacetLocalBBox( int nF, BBox3d& b3Loc, int nFlag = BBF_STANDARD) const = 0 ;
virtual bool GetFacetBBox( int nF, const Frame3d& frRef, BBox3d& b3Ref, int nFlag = BBF_STANDARD) const = 0 ;
virtual int GetEdgeCount( void) const = 0 ;
virtual int GetEdgeSize( void) const = 0 ;
virtual bool GetEdge( int nInd, int& nV1, int& nV2, int& nFl, int& nFr, double& dAng) const = 0 ;
virtual bool GetEdge( int nInd, Point3d& ptP1, Point3d& ptP2, double& dAng) const = 0 ;
virtual bool GetEdges( ICURVEPOVECTOR& vpCurve) const = 0 ;
virtual bool Cut( const Plane3d& plPlane, bool bSaveOnEq) = 0 ;
virtual bool GeneralizedCut( const ICurve& cvCurve, bool bSaveOnEq) = 0 ;
virtual bool Add( const ISurfTriMesh& Other) = 0 ;
+30 -99
View File
@@ -1,21 +1,19 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2023
// EgalTech 2013-2019
//----------------------------------------------------------------------------
// File : EGkVector3d.h Data : 23.08.23 Versione : 2.5h2
// File : EgkVector3d.h Data : 14.12.19 Versione : 2.1l4
// Contenuto : Dichiarazione della classe Vettore 3d.
//
//
//
// Modifiche : 31.12.13 DS Creazione modulo.
// 14.12.19 DS Aggiunti confronti con Epsilon.
// 23.08.23 DS Aggiunto V_INVALID.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkGeoConst.h"
#include <algorithm>
#include <cmath>
//----------------------- Macro per import/export -----------------------------
@@ -45,9 +43,6 @@ class EGK_EXPORT Vector3d
void Set( double dX, double dY, double dZ) { x = dX ; y = dY ; z = dZ ; }
public :
//! Verifica la validità delle coordinate del vettore
bool IsValid( void) const
{ return ( std::isfinite( x) && std::isfinite( y) && std::isfinite( z)) ; }
//! Quadrato della lunghezza del vettore
double SqLen( void) const
{ return ( x * x + y * y + z * z) ; }
@@ -75,60 +70,44 @@ class EGK_EXPORT Vector3d
{ return ( abs( 1.0 - (x * x + y * y + z * z)) < ( 2 * EPS_ZERO)) ; }
//! Verifica se il vettore è parallelo ed equiverso con X+
bool IsXplus( void) const
{ double dMO = std::max( abs( y), abs( z)) ;
return ( x > EPS_ZERO && dMO < 10 * EPS_ZERO && x > KV_BIG * dMO) ; }
{ return ( x > EPS_ZERO && abs( y) < EPS_ZERO && abs( z) < EPS_ZERO) ; }
//! Verifica se il vettore è parallelo ed equiverso con X-
bool IsXminus( void) const
{ double dMO = std::max( abs( y), abs( z)) ;
return ( x < -EPS_ZERO && dMO < 10 * EPS_ZERO && x < -KV_BIG * dMO) ; }
//! Verifica se il vettore è parallelo a X
bool IsX( void) const
{ double dMO = std::max( abs( y), abs( z)) ;
return ( abs( x) > EPS_ZERO && dMO < 10 * EPS_ZERO && abs( x) > KV_BIG * dMO) ; }
{ return ( x < - EPS_ZERO && abs( y) < EPS_ZERO && abs( z) < EPS_ZERO) ; }
//! Verifica se il vettore è parallelo ed equiverso con Y+
bool IsYplus( void) const
{ double dMO = std::max( abs( z), abs( x)) ;
return ( y > EPS_ZERO && dMO < 10 * EPS_ZERO && y > KV_BIG * dMO) ; }
{ return ( abs( x) < EPS_ZERO && y > EPS_ZERO && abs( z) < EPS_ZERO) ; }
//! Verifica se il vettore è parallelo ed equiverso con Y-
bool IsYminus( void) const
{ double dMO = std::max( abs( z), abs( x)) ;
return ( y < -EPS_ZERO && dMO < 10 * EPS_ZERO && y < -KV_BIG * dMO) ; }
//! Verifica se il vettore è parallelo a Y
bool IsY( void) const
{ double dMO = std::max( abs( z), abs( x)) ;
return ( abs( y) > EPS_ZERO && dMO < 10 * EPS_ZERO && abs( y) > KV_BIG * dMO) ; }
{ return ( abs( x) < EPS_ZERO && y < - EPS_ZERO && abs( z) < EPS_ZERO) ; }
//! Verifica se il vettore è parallelo ed equiverso con Z+
bool IsZplus( void) const
{ double dMO = std::max( abs( x), abs( y)) ;
return ( z > EPS_ZERO && dMO < 10 * EPS_ZERO && z > KV_BIG * dMO) ; }
{ return ( abs( x) < EPS_ZERO && abs( y) < EPS_ZERO && z > EPS_ZERO) ; }
//! Verifica se il vettore è parallelo ed equiverso con Z-
bool IsZminus( void) const
{ double dMO = std::max( abs( x), abs( y)) ;
return ( z < -EPS_ZERO && dMO < 10 * EPS_ZERO && z < -KV_BIG * dMO) ; }
//! Verifica se il vettore è parallelo a Z
bool IsZ( void) const
{ double dMO = std::max( abs( x), abs( y)) ;
return ( abs( z) > EPS_ZERO && dMO < 10 * EPS_ZERO && abs( z) > KV_BIG * dMO) ; }
{ return ( abs( x) < EPS_ZERO && abs( y) < EPS_ZERO && z < - EPS_ZERO) ; }
//! Verifica se il vettore è generico
bool IsGeneric( void) const
{ return ( ! IsX() && ! IsY() && ! IsZ()) ; }
{ return (( abs( x) > EPS_ZERO && abs( y) > EPS_ZERO) ||
( abs( y) > EPS_ZERO && abs( z) > EPS_ZERO) ||
( abs( z) > EPS_ZERO && abs( x) > EPS_ZERO)) ; }
//! Somma sul posto con altro vettore
Vector3d& operator +=( const Vector3d& vtV)
{ x += vtV.x ; y += vtV.y ; z += vtV.z ; return *this ; }
{ this->x += vtV.x ; this->y += vtV.y ; this->z += vtV.z ; return *this ; }
//! Sottrazione sul posto con altro vettore
Vector3d& operator -=( const Vector3d& vtV)
{ x -= vtV.x ; y -= vtV.y ; z -= vtV.z ; return *this ; }
{ this->x -= vtV.x ; this->y -= vtV.y ; this->z -= vtV.z ; return *this ; }
//! Moltiplicazione sul posto con un numero
Vector3d& operator *=( double dMul)
{ x *= dMul ; y *= dMul ; z *= dMul ; return *this ; }
{ this->x *= dMul ; this->y *= dMul ; this->z *= dMul ; return *this ; }
//! Divisione sul posto con un numero
Vector3d& operator /=( double dDiv)
{ double dMul = 1 / dDiv ; x *= dMul ; y *= dMul ; z *= dMul ; return *this ; }
{ double dMul = 1 / dDiv ; this->x *= dMul ; this->y *= dMul ; this->z *= dMul ; return *this ; }
//! Ritorna la rappresentazione in coordinate sferiche
void ToSpherical( double* pdLen, double* pdAngVertDeg, double* pdAngOrizzDeg) const ;
//! Inversione del vettore
void Invert( void)
{ x = -x ; y = -y ; z = -z ; }
{ x = - x ; y = - y ; z = - z ; }
//! Normalizzazione del vettore (trasformazione in versore)
bool Normalize( double dEps = EPS_SMALL) ;
//! Rotazione attorno ad un asse, dato l'angolo in gradi
@@ -153,9 +132,7 @@ class EGK_EXPORT Vector3d
bool GetAngleXY( const Vector3d& vtEnd, double& dAngDeg) const ;
//! \brief Calcolo angolo di rotazione per portare la componente del vettore perpendicolare
//! all'asse di rotazione sulla stessa direzione della componente perpendicolare di vtEnd
bool GetRotation( const Vector3d& vtEnd, const Vector3d& vtAx, double dEpsZero, double& dAngDeg, bool& bDet) const ;
bool GetRotation( const Vector3d& vtEnd, const Vector3d& vtAx, double& dAngDeg, bool& bDet) const
{ return GetRotation( vtEnd, vtAx, EPS_ZERO, dAngDeg, bDet) ;}
bool GetRotation( const Vector3d& vtEnd, const Vector3d& vtAx, double& dAngDeg, bool& bDet) const ;
public :
union {
@@ -171,8 +148,6 @@ class EGK_EXPORT Vector3d
//----------------------------------------------------------------------------
// Vettori notevoli
//----------------------------------------------------------------------------
//! Vettore non valido
const Vector3d V_INVALID( NAN, NAN, NAN) ;
//! Vettore nullo
const Vector3d V_NULL( 0, 0, 0) ;
//! Versore asse X
@@ -197,15 +172,10 @@ EGK_EXPORT Vector3d FromPolar( double dLen, double dAngDeg) ;
//----------------------------------------------------------------------------
EGK_EXPORT Vector3d FromUprightOrtho( const Vector3d& vtV) ;
//----------------------------------------------------------------------------
//! Definizione come ortogonale al primo ricevuto, orizzontale e più vicino al secondo
//----------------------------------------------------------------------------
EGK_EXPORT Vector3d FromNearestHorizontalOrtho( const Vector3d& vtV, const Vector3d& vtNear) ;
//----------------------------------------------------------------------------
//! Opposto di un vettore
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator-( const Vector3d& vtV)
{
return ( Vector3d( - vtV.x, - vtV.y, - vtV.z)) ;
@@ -214,7 +184,7 @@ operator-( const Vector3d& vtV)
//----------------------------------------------------------------------------
//! Somma di due vettori
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator+( const Vector3d& vtV1, const Vector3d& vtV2)
{
return ( Vector3d( vtV1.x + vtV2.x, vtV1.y + vtV2.y, vtV1.z + vtV2.z)) ;
@@ -223,7 +193,7 @@ operator+( const Vector3d& vtV1, const Vector3d& vtV2)
//----------------------------------------------------------------------------
//! Sottrazione di due vettori
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator-( const Vector3d& vtV1, const Vector3d& vtV2)
{
return ( Vector3d( vtV1.x - vtV2.x, vtV1.y - vtV2.y, vtV1.z - vtV2.z)) ;
@@ -232,7 +202,7 @@ operator-( const Vector3d& vtV1, const Vector3d& vtV2)
//----------------------------------------------------------------------------
//! Prodotto con uno scalare
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator*( const Vector3d& vtV, double dMul)
{
return ( Vector3d( vtV.x * dMul, vtV.y * dMul, vtV.z * dMul)) ;
@@ -241,7 +211,7 @@ operator*( const Vector3d& vtV, double dMul)
//----------------------------------------------------------------------------
//! Prodotto di uno scalare con un vettore
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator*( double dMul, const Vector3d& vtV)
{
return ( Vector3d( vtV.x * dMul, vtV.y * dMul, vtV.z * dMul)) ;
@@ -250,7 +220,7 @@ operator*( double dMul, const Vector3d& vtV)
//----------------------------------------------------------------------------
//! Divisione con uno scalare
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator/( const Vector3d& vtV, double dDiv)
{
double dMul = 1 / dDiv ;
@@ -278,7 +248,7 @@ ScalarXY( const Vector3d& vtV1, const Vector3d& vtV2)
//----------------------------------------------------------------------------
//! Prodotto vettoriale
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
operator^( const Vector3d& vtV1, const Vector3d& vtV2)
{
return ( Vector3d( vtV1.y * vtV2.z - vtV1.z * vtV2.y,
@@ -298,8 +268,8 @@ CrossXY( const Vector3d& vtV1, const Vector3d& vtV2)
//----------------------------------------------------------------------------
//! Somma mediata di due vettori (baricentrica)
//----------------------------------------------------------------------------
inline const Vector3d
Media( const Vector3d& vtV1, const Vector3d& vtV2, double dCoeff = 0.5)
inline Vector3d
Media( const Vector3d& vtV1, const Vector3d& vtV2, double dCoeff)
{
return ( Vector3d( ( 1 - dCoeff) * vtV1.x + dCoeff * vtV2.x,
( 1 - dCoeff) * vtV1.y + dCoeff * vtV2.y,
@@ -309,25 +279,19 @@ Media( const Vector3d& vtV1, const Vector3d& vtV2, double dCoeff = 0.5)
//----------------------------------------------------------------------------
//! Restituisce il componente del vettore parallelo a quello di riferimento
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
ParallCompo( const Vector3d& vtV, const Vector3d& vtRef)
{
if ( vtRef.IsNormalized())
return ( ( vtV * vtRef) * vtRef) ;
else
return ( ( vtV * vtRef) * vtRef / vtRef.SqLen()) ;
return ( ( vtV * vtRef) * vtRef) ;
}
//----------------------------------------------------------------------------
//! Restituisce il componente del vettore ortogonale a quello di riferimento
//----------------------------------------------------------------------------
inline const Vector3d
inline Vector3d
OrthoCompo( const Vector3d& vtV, const Vector3d& vtRef)
{
if ( vtRef.IsNormalized())
return ( vtV - ( vtV * vtRef) * vtRef) ;
else
return ( vtV - ( vtV * vtRef) * vtRef / vtRef.SqLen()) ;
return ( vtV - ( vtV * vtRef) * vtRef) ;
}
//----------------------------------------------------------------------------
@@ -428,36 +392,3 @@ AreOrthoExact( const Vector3d& vtV1, const Vector3d& vtV2)
{
return ( abs( vtV1 * vtV2) < COS_ORTO_ANG_ZERO) ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in locale del vettore passato
//----------------------------------------------------------------------------
inline const Vector3d
GetToLoc( const Vector3d& vtV, const Frame3d& frRef)
{
Vector3d vtW = vtV ;
vtW.ToLoc( frRef) ;
return vtW ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia in globale del vettore passato
//----------------------------------------------------------------------------
inline const Vector3d
GetToGlob( const Vector3d& vtV, const Frame3d& frRef)
{
Vector3d vtW = vtV ;
vtW.ToGlob( frRef) ;
return vtW ;
}
//----------------------------------------------------------------------------
//! Restituisce una copia dal primo al secondo riferimento del vettore passato
//----------------------------------------------------------------------------
inline const Vector3d
GetLocToLoc( const Vector3d& vtV, const Frame3d& frOri, const Frame3d& frDest)
{
Vector3d vtW = vtV ;
vtW.LocToLoc( frOri, frDest) ;
return vtW ;
}
+17 -21
View File
@@ -1,13 +1,12 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2023
// EgalTech 2015-2020
//----------------------------------------------------------------------------
// File : EGkVolZmap.h Data : 12.09.23 Versione : 2.5i1
// File : EgkVolZmap.h Data : 12.05.19 Versione : 2.2k1
// Contenuto : Dichiarazione della interfaccia IVolZmap.
//
//
//
// Modifiche : 22.01.15 DS Creazione modulo.
// 12.09.23 DS Aggiunto metodo IsTriDexel.
//
//
//----------------------------------------------------------------------------
@@ -56,37 +55,34 @@ class __declspec( novtable) IVolZmap : public IGeoObj
virtual bool Create( const Point3d& ptO, double dDimX, double dDimY, double dDimZ, double dPrec, bool bTriDex) = 0 ;
virtual bool CreateFromFlatRegion( const ISurfFlatRegion& Surf, double dDimZ, double dPrec, bool bTriDex) = 0 ;
virtual bool CreateFromTriMesh( const ISurfTriMesh& Surf, double dPrec, bool bTriDex) = 0 ;
virtual bool CreateEmptyMap( const Point3d& ptO, double dLengthX, double dLengthY, double dLengthZ, double dStep, bool bTriDex) = 0 ;
virtual int GetBlockCount( void) const = 0 ;
virtual int GetBlockUpdatingCounter( int nBlock) const = 0 ;
virtual bool GetBlockTriangles( int nBlock, TRIA3DEXVECTOR& vTria) const = 0 ;
virtual bool GetEdges( ICURVEPOVECTOR& vpCurve) const = 0 ;
virtual bool GetVolume( double& dVol) const = 0 ;
virtual bool IsTriDexel( void) const = 0 ;
virtual bool GetDexelLines( int nDir, int nPos1, int nPos2, POLYLINELIST& lstPL) const = 0 ;
virtual int GetResolution( void) const = 0 ;
virtual bool ChangeResolution( int nDexvoxRatio) = 0 ;
virtual bool SetToolTolerances( double dLinTol, double dAngTolDeg = 90) = 0 ;
virtual bool SetStdTool( const std::string& sToolName,
double dH, double dR, double dCornR, double dCutterH, int nFlag, bool bFirst) = 0 ;
virtual bool SetStdTool( const std::string& sToolName, double dH, double dR, double dCornR, double dCutterH, int nFlag) = 0 ;
virtual bool SetAdvTool( const std::string& sToolName,
double dH, double dR, double dTipH, double dTipR, double dCornR, double dCutterH, int nFlag, bool bFirst) = 0 ;
double dH, double dR, double dTipH, double dTipR, double dCornR, double dCutterH, int nFlag) = 0 ;
virtual bool SetSawTool( const std::string& sToolName,
double dH, double dR, double dThick, double dStemR, double dCornR, int nFlag, bool bFirst) = 0 ;
virtual bool SetGenTool( const std::string& sToolName,
const ICurveComposite* pToolOutline, int nFlag, bool bFirst) = 0 ;
virtual bool SetMortiserTool( const std::string& sToolName,
double dH, double dW, double dTh, double dRc, int nFlag, bool bFirst) = 0 ;
virtual bool SetChiselTool( const std::string& sToolName,
double dH, double dW, double dTh, int nFlag, bool bFirst) = 0 ;
virtual int GetToolCount( void) const = 0 ;
double dH, double dR, double dThick, double dStemR, double dCornR, int nFlag) = 0 ;
virtual bool SetGenTool( const std::string& sToolName, const ICurveComposite* pToolOutline, int nFlag) = 0 ;
virtual bool SetMortiserTool( const std::string& sToolName, double dH, double dW, double dTh, double dRc, int nFlag) = 0 ;
virtual bool SetChiselTool( const std::string& sToolName, double dH, double dW, double dTh, int nFlag) = 0 ;
virtual bool SetAdditiveTool( const std::string& sToolName, double dH, double dR, double dRC, int nFlag) = 0 ;
virtual bool SetCurrTool( int nCurrTool) = 0 ;
virtual bool ResetTools( void) = 0 ;
virtual int GetToolCount( void) const = 0 ;
virtual int GetCurrTool( void) const = 0 ;
virtual bool AddTool( void) = 0 ;
virtual bool ResetAllTools( void) = 0 ;
virtual bool ResetTool( void) = 0 ;
virtual const ICurveComposite& GetToolOutline( bool bApprox = false) const = 0 ;
virtual bool MillingStep( int nCurrTool,
const Point3d& ptPs, const Vector3d& vtDs,
const Point3d& ptPe, const Vector3d& vtDe) = 0 ;
virtual bool MillingStep( int nCurrTool,
const Point3d& ptPs, const Vector3d& vtDs, const Vector3d& vtAs,
virtual bool MillingStep( const Point3d& ptPs, const Vector3d& vtDs, const Point3d& ptPe, const Vector3d& vtDe) = 0 ;
virtual bool MillingStep( const Point3d& ptPs, const Vector3d& vtDs, const Vector3d& vtAs,
const Point3d& ptPe, const Vector3d& vtDe, const Vector3d& vtAe) = 0 ;
virtual bool GetDepth( const Point3d& ptP, const Vector3d& vtDir, double& dInLength, double& dOutLength, bool bExact) const = 0 ;
virtual bool GetLineIntersection( const Point3d& ptP, const Vector3d& vtD, ILZIVECTOR& vIntersInfo) const = 0 ;
-93
View File
@@ -1,93 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2023
//----------------------------------------------------------------------------
// File : EGkVoronoi.h Data : 23.11.23 Versione : 2.5k5
// Contenuto : Dichiarazione della classe Voronoi con libreria VRONI
//
//
//
// Modifiche : 23.11.23 SP Creazione modulo.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGkFrame3d.h"
#include "/EgtDev/Include/EGkCurve.h"
#include "/EgtDev/Include/EGkCurveArc.h"
#include "/EgtDev/Include/EGkCurveBezier.h"
#include "/EgtDev/Include/EGkCurveComposite.h"
#include "/EgtDev/Include/EGkCurveLine.h"
#include "/EgtDev/Extern/vroni/Include/vroni_object.h"
//----------------------- Macro per import/export ----------------------------
#undef EGK_EXPORT
#if defined( I_AM_EGK) // da definirsi solo nella DLL
#define EGK_EXPORT __declspec( dllexport)
#else
#define EGK_EXPORT __declspec( dllimport)
#endif
static const int VORONOI_STD_BOUND = 3 ;
static const double VRONI_OFFS_TOL = 1e-14 ;
//-------------------------- Forward Definitions -------------------------------
class ISurfFlatRegion ;
//----------------------------------------------------------------------------
class Voronoi
{
public :
// costanti per il lato del medial axis
enum WMATSide { WMAT_LEFT = 0,
WMAT_RIGHT = 1,
WMAT_BOTHSIDES = 2} ;
public :
EGK_EXPORT Voronoi( void)
: m_vroni( nullptr), m_nBound( VORONOI_STD_BOUND), m_bVDComputed( false), m_bAllowAdd( true) {} ;
EGK_EXPORT Voronoi( const ICurve* pCrv, bool bAllowAdd) ;
EGK_EXPORT Voronoi( const ISurfFlatRegion* pSfr, bool bAllowAdd) ;
EGK_EXPORT ~Voronoi( void) ;
public :
EGK_EXPORT bool AddCurve( const ICurve* pCrv) ;
EGK_EXPORT bool AddSurfFlatRegion( const ISurfFlatRegion* pSfr) ;
EGK_EXPORT ICurve* GetCurve( int nId) const ;
EGK_EXPORT int GetCurveCount( void) const
{ return m_vpCrvs.size() ; } ;
EGK_EXPORT bool CalcVoronoiDiagram( ICURVEPOVECTOR& vCrvs, int nBound = VORONOI_STD_BOUND) ;
EGK_EXPORT bool CalcOffset( ICURVEPOVECTOR& vOffs, double dOffs, int nType) ;
EGK_EXPORT bool CalcFatCurve( ICURVEPOVECTOR& vOffs, double dOffs, bool bSquareEnds, bool bSquareMids) ;
EGK_EXPORT bool CalcMedialAxis( ICURVEPOVECTOR& vCrvs, int nSide) ;
private :
bool Clear( void) ;
bool IsValid( void) const
{ return m_vroni != nullptr ; } ;
bool AddCurveToVroni( const ICurve * pCrv) ;
bool AddLineToVroni( const ICurveLine* pLine, int& nVroniCrv, int nLoopId, int nCrvId = 0, Point3d ptForcedEnd = P_INVALID) ;
bool AddArcToVroni( const ICurveArc* pArc, int& nVroniCrv, int nLoopId, int nCrvId = 0, Point3d ptForcedEnd = P_INVALID) ;
bool AddCompoToVroni( const ICurveComposite* pCompo, int& nCrv, int nLoopId) ;
bool AddBezierToVroni( const ICurveBezier* pBezier, int& nVroniCrv, int nLoopId) ;
bool CalcVoronoi( int nBound = VORONOI_STD_BOUND) ;
bool CalcVroniOffset( ICRVCOMPOPLIST& vOffs, double dOffs, bool bRightOffs, bool bLeftOffs) ;
bool UpdateVoronoi( double dOffs) ;
bool VerifyCurvesValidityForOffset( void) ;
bool AdjustOpenOffsetCurve( ICurveComposite& pCompo, double dOffs) ;
bool AdjustOffsetStart( ICurveComposite& pCompo) ;
int GetOffsetCurveSide( const ICurveComposite& pOffs, int nCrv) ;
ICurve* GetBisectorCurve( int i) ;
private :
vroniObject* m_vroni ; // oggetto base della libreria vroni
Frame3d m_Frame ; // frame in cui è espresso l'oggetto vroni
int m_nBound ; // bound associato al diagramma di Voronoi corrente
CICURVEPVECTOR m_vpCrvs ; // curve associate al Voronoi ( espresse rispetto a m_Frame)
BBox3d m_bBox ; // box degli oggetti associati al Voronoi
bool m_bVDComputed ; // indica se il diagramma di Voronoi è stato calcolato
bool m_bAllowAdd ; // indica se possibile aggiungere altre curve/superifici dopo aver creato l'oggetto Voronoi
} ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGnCmdExecutor.h Data : 21.03.14 Versione : 1.5c3
// File : EgnCmdExecutor.h Data : 21.03.14 Versione : 1.5c3
// Contenuto : Dichiarazione della interfaccia ICmdExecutor.
//
//
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGnCmdParser.h Data : 15.03.14 Versione : 1.5c
// File : EgnCmdParser.h Data : 15.03.14 Versione : 1.5c
// Contenuto : Dichiarazione della interfaccia ICmdParser.
//
//
+1 -7
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGnDllMain.h Data : 21.11.13 Versione : 1.4l2
// File : EgnDllMain.h Data : 21.11.13 Versione : 1.4l2
// Contenuto : Prototipi funzioni generali della DLL.
//
//
@@ -28,9 +28,3 @@ class ILogger ;
EGN_EXPORT const char* GetEGnVersion( void) ;
// permette di impostare il logger per la Dll
EGN_EXPORT void SetEGnLogger( ILogger* pLogger) ;
// imposta la chiave di protezione
EGN_EXPORT void SetEGnKey( const std::string& sKey) ;
// imposta il tipo di chiave di protezione
EGN_EXPORT void SetEGnKeyType( int nType) ;
// imposta se chiave hardware di rete
EGN_EXPORT void SetEGnNetHwKey( bool bNetHwKey) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2019
//----------------------------------------------------------------------------
// File : EGnFileCompare.h Data : 09.12.19 Versione : 2.1l4
// File : EgnFileCompare.h Data : 09.12.19 Versione : 2.1l4
// Contenuto : Prototipi funzioni di confronto tra file.
//
//
+4 -6
View File
@@ -1,19 +1,19 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2022
// EgalTech 2013-2020
//----------------------------------------------------------------------------
// File : EGnFileUtils.h Data : 09.04.22 Versione : 2.4d1
// File : EgnFileUtils.h Data : 30.11.20 Versione : 2.2k
// Contenuto : Prototipi funzioni di utilità su file e direttori.
//
//
//
// Modifiche : 11.12.13 DS Creazione modulo.
// 09.04.22 DS Aggiunta FindAllFiles.
//
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EgtStringBase.h"
#include <string>
//----------------------- Macro per import/export ----------------------------
@@ -34,7 +34,6 @@ EGN_EXPORT std::string GetFileExtension( const std::string& sFile) ;
EGN_EXPORT std::string ChangeFileExtension( const std::string& sFile, const std::string& sNewExt) ;
EGN_EXPORT bool FileExtensionMatches( const std::string& sFile, const std::string& sExt) ;
EGN_EXPORT bool FindFirstFileEgt( const std::string& sFileSpec, std::string& sFileName) ;
EGN_EXPORT bool FindAllFiles( const std::string& sFileSpec, STRVECTOR& vsFileNames) ;
EGN_EXPORT std::string GetFileName( const std::string& sPath) ;
EGN_EXPORT std::string GetFileTitleEgt( const std::string& sPath) ;
EGN_EXPORT std::string GetDirectory( const std::string& sPath) ;
@@ -42,4 +41,3 @@ EGN_EXPORT bool ExistsDirectory( const std::string& sDir) ;
EGN_EXPORT bool CreateDirectoryEgt( const std::string& sDir) ;
EGN_EXPORT bool EmptyDirectory( const std::string& sDir) ;
EGN_EXPORT bool EraseDirectory( const std::string& sDir) ;
EGN_EXPORT bool FindAllDirectories( const std::string& sDirSpec, STRVECTOR& vsDirNames) ;
-36
View File
@@ -1,36 +0,0 @@
//----------------------------------------------------------------------------
// EgalTech 2023-2023
//----------------------------------------------------------------------------
// File : EGnGetKeyData.h Data : 29.05.23 Versione : 2.5e3
// Contenuto : Prototipo funzioni gestione dati chiavi di protezione.
//
//
//
// Modifiche : 29.05.23 DS Creazione modulo.
//
//
//----------------------------------------------------------------------------
#pragma once
#define NOMINMAX
#include <windows.h>
#include <string>
//----------------------- Macro per import/export ----------------------------
#undef EGN_EXPORT
#if defined( I_AM_EGN) // da definirsi solo nella DLL
#define EGN_EXPORT __declspec( dllexport)
#else
#define EGN_EXPORT __declspec( dllimport)
#endif
//-----------------------------------------------------------------------------
EGN_EXPORT bool SetEGnKeyLevel( int nRet, int nKeyLev, int nKeyExpDays) ;
EGN_EXPORT int GetEGnKeyLevel( int nProd, int nVer, int nLev, int& nKeyLev, int& nKeyExpDays) ;
EGN_EXPORT bool SetEGnKeyOptions( int nRet, int nKeyOpt1, int nKeyOpt2, int nKeyOptExpDays) ;
EGN_EXPORT int GetEGnKeyOptions( int nProd, int nVer, int nLev, unsigned int& nKeyOpt1, unsigned int& nKeyOpt2, int& nKeyOptExpDays) ;
// Interpretazione della stringa di LockId
EGN_EXPORT bool GetLockIdStringInfo( const std::string& sLockId, int& nKeyType, bool& bNetKey, int& nUserId) ;
EGN_EXPORT bool GetLockIdStringNetData( const std::string& sLockId, std::string& sAddrPort) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2013
//----------------------------------------------------------------------------
// File : EGnGetModuleVer.h Data : 10.12.13 Versione : 1.4a4
// File : EgnGetModuleVer.h Data : 10.12.13 Versione : 1.4a4
// Contenuto : Prototipo funzione calcolo versione del modulo richiesto.
//
//
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGnLuaMgr.h Data : 21.03.15 Versione : 1.6c6
// File : EgnLuaMgr.h Data : 21.03.15 Versione : 1.6c6
// Contenuto : Dichiarazione della classe LuaMgr.
//
//
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGnScanner.h Data : 06.03.14 Versione : 1.5c1
// File : EgnScanner.h Data : 06.03.14 Versione : 1.5c1
// Contenuto : Dichiarazione della classe CScan.
//
//
+15 -38
View File
@@ -1,44 +1,42 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2022
// EgalTech 2015-2018
//----------------------------------------------------------------------------
// File : EGnStringKeyVal.h Data : 13.05.22 Versione : 2.4e2
// File : EGnStringKeyVal.h Data : 27.11.18 Versione : 1.9k1
// Contenuto : Funzioni per gestione coppie chiave-valore in stringhe.
//
//
//
// Modifiche : 23.05.15 DS Creazione modulo.
// 27.11.18 DS Aggiunte Set/Get/RemoveValInNotes.
// 13.05.22 DS In SetValInNotes e GetValInNotes aggiunta gestione separatore ':'.
//
//----------------------------------------------------------------------------
#pragma once
#include "/EgtDev/Include/EGnStringUtils.h"
#include "/EgtDev/Include/EgnStringUtils.h"
//----------------------------------------------------------------------------
static const char EQUAL = '=' ;
static const char COLON = ':' ;
//----------------------------------------------------------------------------
inline bool
IsValidKey( const std::string& sKey, bool bFull = false)
IsValidKey( const std::string& sKey)
{
return ( ! sKey.empty() &&
sKey.find( '\n') == std::string::npos &&
(( bFull && ( sKey.back() == EQUAL || sKey.back() == COLON)) ||
sKey.find( EQUAL) == std::string::npos) &&
sKey.find( EQUAL) == std::string::npos &&
sKey.find_first_not_of( " \t\r\n") != std::string::npos) ;
}
//----------------------------------------------------------------------------
inline bool
FindKey( const std::string& sString, const std::string& sKey, bool bFull = false)
FindKey( const std::string& sString, const std::string& sKey)
{
if ( sString.empty() || ! IsValidKey( sKey, bFull))
if ( sString.empty() || ! IsValidKey( sKey))
return false ;
return ( sString.compare( 0, sKey.length(), sKey) == 0 &&
( bFull || ( sString.length() > sKey.length() && sString[sKey.length()] == EQUAL))) ;
sString.length() > sKey.length() &&
sString[sKey.length()] == EQUAL) ;
}
//----------------------------------------------------------------------------
@@ -101,28 +99,20 @@ GetVal( const std::string& sString, const std::string& sKey, T& Val)
inline bool
SetValInNotes( const std::string& sKey, const std::string& sVal, std::string& sNotes)
{
// verifiche validità chiave
if ( ! IsValidKey( sKey) || ! IsValidVal( sVal))
return false ;
// chiave con carattere finale speciale
std::string sTkey = sKey ;
if ( sKey.back() != COLON)
sTkey += EQUAL ;
// ricerca se già presente
STRVECTOR vsTokens ;
Tokenize( sNotes, ";", vsTokens) ;
bool bFound = false ;
for ( auto& sToken : vsTokens) {
if ( FindKey( sToken, sTkey, true)) {
sToken = sTkey + sVal ;
if ( FindKey( sToken, sKey)) {
sToken = sKey + EQUAL + sVal ;
bFound = true ;
break ;
}
}
// altrimenti aggiunta
if ( ! bFound)
vsTokens.emplace_back( sTkey + sVal) ;
// ricostruzione delle note
vsTokens.emplace_back( sKey + EQUAL + sVal) ;
sNotes.clear() ;
for ( const auto& sToken : vsTokens) {
if ( ! IsEmptyOrSpaces( sToken))
@@ -143,19 +133,13 @@ SetValInNotes( const std::string& sKey, T& Val, std::string& sNotes)
inline bool
GetValInNotes( const std::string& sNotes, const std::string& sKey, std::string& sVal)
{
// verifiche validità chiave
if ( sNotes.empty() || ! IsValidKey( sKey))
return false ;
// chiave con carattere finale speciale
std::string sTkey = sKey ;
if ( sKey.back() != COLON)
sTkey += EQUAL ;
// ricerca
STRVECTOR vsTokens ;
Tokenize( sNotes, ";", vsTokens) ;
for ( const auto& sToken : vsTokens) {
if ( FindKey( sToken, sTkey, true)) {
sVal = sToken.substr( sTkey.length()) ;
if ( FindKey( sToken, sKey)) {
sVal = sToken.substr( sKey.length() + 1) ;
return true ;
}
}
@@ -175,25 +159,18 @@ GetValInNotes( const std::string& sNotes, const std::string& sKey, T& Val)
inline bool
RemoveValInNotes( const std::string& sKey, std::string& sNotes)
{
// verifiche validità chiave
if ( sNotes.empty() || ! IsValidKey( sKey))
return false ;
// chiave con carattere finale speciale
std::string sTkey = sKey ;
if ( sKey.back() != COLON)
sTkey += EQUAL ;
// ricerca
STRVECTOR vsTokens ;
Tokenize( sNotes, ";", vsTokens) ;
bool bFound = false ;
for ( size_t i = 0; i < vsTokens.size() ; ++ i) {
if ( FindKey( vsTokens[i], sTkey, true)) {
if ( FindKey( vsTokens[i], sKey)) {
vsTokens.erase( vsTokens.begin() + i) ;
bFound = true ;
break ;
}
}
// se trovato e cancellato, devo ricostruire le note
if ( bFound) {
sNotes.clear() ;
for ( const auto& sToken : vsTokens) {
+5 -5
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2013-2014
//----------------------------------------------------------------------------
// File : EGnStringUtils.h Data : 17.03.14 Versione : 1.5c2
// File : EgnStringUtils.h Data : 17.03.14 Versione : 1.5c2
// Contenuto : Dichiarazione delle funzioni di utilità per le stringhe.
//
//
@@ -196,11 +196,11 @@ EGN_EXPORT bool FromString( const std::string& sVal, STRVECTOR& vsVal) ;
//----------------------------------------------------------------------------
inline const std::string
ToString( int nVal, int nPrec = 1, int nRadix = 10)
ToString( int nVal, int nPrec = 1)
{
// eseguo conversione
char szBuff[24] ;
int nErr = _itoa_s( nVal, szBuff, nRadix) ;
int nErr = _itoa_s( nVal, szBuff, 10) ;
// se errore, ritorno stringa opportuna
if ( nErr != 0) {
_ASSERT( 0) ;
@@ -216,11 +216,11 @@ ToString( int nVal, int nPrec = 1, int nRadix = 10)
return sBuff ;
}
inline const std::string
ToString( unsigned int nVal, int nPrec = 1, int nRadix = 10)
ToString( unsigned int nVal, int nPrec = 1)
{
// eseguo conversione
char szBuff[24] ;
int nErr = _ultoa_s( nVal, szBuff, nRadix) ;
int nErr = _ui64toa_s( nVal, szBuff, 24, 10) ;
// se errore, ritorno stringa opportuna
if ( nErr != 0) {
_ASSERT( 0) ;
+1 -1
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2015
//----------------------------------------------------------------------------
// File : EGnWriter.h Data : 02.06.15 Versione : 1.6f1
// File : EgnWriter.h Data : 02.06.15 Versione : 1.6f1
// Contenuto : Dichiarazione della classe Writer.
//
//
+1 -3
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGrDllMain.h Data : 13.02.14 Versione : 1.5b1
// File : EgrDllMain.h Data : 13.02.14 Versione : 1.5b1
// Contenuto : Prototipi funzioni generali della DLL.
//
//
@@ -32,8 +32,6 @@ extern "C" {
EGR_EXPORT void SetEGrLogger( ILogger* pLogger) ;
// imposta la chiave di protezione
EGR_EXPORT void SetEGrKey( const std::string& sKey) ;
// imposta se chiave hardware di rete
EGR_EXPORT void SetEGrNetHwKey( bool bNetHwKey) ;
}
+2 -2
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EGrSceExecutor.h Data : 18.02.14 Versione : 1.5b3
// File : EgrSceExecutor.h Data : 18.02.14 Versione : 1.5b3
// Contenuto : Dichiarazione della interfaccia ISceExecutor.
//
//
@@ -13,7 +13,7 @@
#pragma once
#include "/EgtDev/Include/EGnCmdExecutor.h"
#include "/EgtDev/Include/EgnCmdExecutor.h"
class IEGrScene ;
+2 -7
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2024
// EgalTech 2014-2019
//----------------------------------------------------------------------------
// File : EGrScene.h Data : 09.01.24 Versione : 2.5l7
// File : EGrScene.h Data : 13.02.14 Versione : 2.1i2
// Contenuto : Dichiarazione della interfaccia IEGrScene per scena OpenGL.
//
//
@@ -64,7 +64,6 @@ class IEGrScene
virtual void GetCamera( double* pdAngVertDeg, double* pdAngOrizzDeg, double* pdDist = nullptr) const = 0 ;
virtual int GetCameraDir( void) const = 0 ;
virtual const Vector3d& GetCameraUp( void) const = 0 ;
virtual void GetOrthoCamParam(double* pdWidth, double* pdHeight, double* pdNear, double* pdFar) const = 0 ;
virtual bool PanCamera( const Point3d& ptWinOld, const Point3d& ptWinNew) = 0 ;
virtual bool RotateCamera( const Point3d& ptWinOld, const Point3d& ptWinNew) = 0 ;
virtual bool ZoomAll( void) = 0 ;
@@ -93,11 +92,7 @@ class IEGrScene
// Grid
virtual bool SetGridShow( bool bShowGrid, bool bShowFrame) = 0 ;
virtual bool SetGridGeo( double dSnapStep, int nMinLineSstep, int nMajLineSstep, int nExtSstep) = 0 ;
virtual bool SetGridGeoAdv( double dSnapStep, int nMinLineSstep, int nMajLineSstep,
double dXmin, double dXmax, double dYmin, double dYmax) = 0 ;
virtual bool SetGridColor( Color colMinLine, Color colMajLine) = 0 ;
virtual void GetGridParam( double& dSnapStep, int& nExtStep) const = 0 ;
virtual bool GetShowGrid( void) = 0 ;
// Glob Frame
virtual bool SetGlobFrameShow( bool bShow) = 0 ;
// Direct
+9 -53
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2014-2024
// EgalTech 2014-2014
//----------------------------------------------------------------------------
// File : EInAPI.h Data : 09.01.24 Versione : 2.5l6
// File : EInAPI.h Data : 26.08.14 Versione : 1.5h1
// Contenuto : API (application programming interface).
//
//
@@ -34,10 +34,6 @@ extern "C" {
// General
EIN_EXPORT BOOL __stdcall EgtInit( int nDebug, const wchar_t* wsLogFile, const wchar_t* wsLogMsg) ;
EIN_EXPORT BOOL __stdcall EgtExit( void) ;
typedef bool (__stdcall * pfOnTerminateProcess) ( int) ;
EIN_EXPORT BOOL __stdcall EgtSetOnTerminateProcess( pfOnTerminateProcess pFun) ;
EIN_EXPORT BOOL __stdcall EgtSetUserLevel( int nUserLev) ;
EIN_EXPORT int __stdcall EgtGetUserLevel( void) ;
EIN_EXPORT BOOL __stdcall EgtSetKey( const wchar_t* wsKey) ;
EIN_EXPORT BOOL __stdcall EgtSetNestKey( const wchar_t* wsNestKey) ;
EIN_EXPORT BOOL __stdcall EgtSetFont( const wchar_t* wsNfeFontDir, const wchar_t* wsDefaultFont) ;
@@ -52,8 +48,6 @@ EIN_EXPORT void __stdcall EgtDisableCommandLogger( void) ;
EIN_EXPORT BOOL __stdcall EgtGetVersionInfo( wchar_t*& wsVer) ;
EIN_EXPORT BOOL __stdcall EgtGetKeyInfo( wchar_t*& wsKey) ;
EIN_EXPORT BOOL __stdcall EgtSetLockType( int nType) ;
EIN_EXPORT BOOL __stdcall EgtSetLockId( const wchar_t* wsLockId) ;
EIN_EXPORT BOOL __stdcall EgtSetNetHwKey( BOOL bNetHwKey) ;
EIN_EXPORT BOOL __stdcall EgtGetKeyLevel( int nProd, int nVer, int nLev, int* pnKLev) ;
EIN_EXPORT BOOL __stdcall EgtGetKeyOptions( int nProd, int nVer, int nLev, unsigned int* pnOpt2) ;
EIN_EXPORT BOOL __stdcall EgtGetKeyLeftDays( int* pnLeftDays) ;
@@ -115,16 +109,12 @@ EIN_EXPORT BOOL __stdcall EgtImportDxf( const wchar_t* wsFilePath, double dScale
EIN_EXPORT BOOL __stdcall EgtImportPnt( const wchar_t* wsFilePath, int nFlag) ;
EIN_EXPORT BOOL __stdcall EgtImportStl( const wchar_t* wsFilePath, double dScaleFactor) ;
EIN_EXPORT BOOL __stdcall EgtImport3MF( const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtImport3dm( const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtAdvancedImportIsEnabled( void) ;
EIN_EXPORT BOOL __stdcall EgtAdvancedImport( const wchar_t* wsFilePath, double dLinToler) ;
EIN_EXPORT BOOL __stdcall EgtExportDxf( int nId, const wchar_t* wsFilePath, int nFlag, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtExportStl( int nId, const wchar_t* wsFilePath, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtExport3MF( int nId, const wchar_t* wsFilePath, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtExport3dm( int nId, const wchar_t* wsFilePath, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtExportSvg( int nId, const wchar_t* wsFilePath, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtSetThreeJSLibDir( const wchar_t* wsThreeJSLibDir) ;
EIN_EXPORT BOOL __stdcall EgtExportThreeJS( int nId, const wchar_t* wsFilePath, int nFilter) ;
EIN_EXPORT BOOL __stdcall EgtExportDxf( int nId, const wchar_t* wsFilePath, int nFlag) ;
EIN_EXPORT BOOL __stdcall EgtExportStl( int nId, const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtExport3MF( int nId, const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtExportSvg( int nId, const wchar_t* wsFilePath) ;
// BeamManager
EIN_EXPORT BOOL __stdcall EgtInitBeamMgr( int nFlag) ;
@@ -137,11 +127,6 @@ EIN_EXPORT BOOL __stdcall EgtBeamSetPartProdNbr( int nProdNbr) ;
EIN_EXPORT BOOL __stdcall EgtBeamSetPartName( const wchar_t* wsName) ;
EIN_EXPORT BOOL __stdcall EgtBeamSetPartCount( int nCount) ;
EIN_EXPORT BOOL __stdcall EgtBeamSetPartBox( double dLength, double dHeight, double dWidth, BOOL bUpdate) ;
EIN_EXPORT BOOL __stdcall EgtBeamGetSideData( int nSide,
double ptOrig[3], double vtX[3], double vtY[3], double vtZ[3],
double* pdLength, double* pdWidth, double* pdHeight) ;
EIN_EXPORT BOOL __stdcall EgtBeamShowFacesName( BOOL bShow) ;
EIN_EXPORT BOOL __stdcall EgtBeamShowLoadingSide( BOOL bShow, BOOL bFromLeft) ;
EIN_EXPORT 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, const wchar_t* wsUAtts,
@@ -178,12 +163,11 @@ EIN_EXPORT BOOL __stdcall EgtLuaGetGlobStringVar( const wchar_t* wsVar, wchar_t*
EIN_EXPORT BOOL __stdcall EgtLuaGetGlobVectorVar( const wchar_t* wsVar, double vtVal[3]) ;
EIN_EXPORT BOOL __stdcall EgtLuaGetGlobPointVar( const wchar_t* wsVar, double ptVal[3]) ;
EIN_EXPORT BOOL __stdcall EgtLuaResetGlobVar( const wchar_t* wsVar) ;
EIN_EXPORT BOOL __stdcall EgtLuaExistsFunction( const wchar_t* wsFun) ;
EIN_EXPORT BOOL __stdcall EgtLuaCallFunction( const wchar_t* wsFun) ;
EIN_EXPORT BOOL __stdcall EgtLuaEvalNumExpr( const wchar_t* wsExpr, double* pdVal) ;
EIN_EXPORT BOOL __stdcall EgtLuaEvalStringExpr( const wchar_t* wsExpr, wchar_t*& wsVal) ;
EIN_EXPORT BOOL __stdcall EgtLuaExecLine( const wchar_t* wsLine) ;
EIN_EXPORT BOOL __stdcall EgtLuaExecFile( const wchar_t* wsFilePath, BOOL bLogInfo) ;
EIN_EXPORT BOOL __stdcall EgtLuaExecFile( const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtLuaRequire( const wchar_t* wsFilePath) ;
EIN_EXPORT BOOL __stdcall EgtLuaGetLastError( wchar_t*& wsError) ;
@@ -228,8 +212,6 @@ EIN_EXPORT int __stdcall EgtCreateCircleCP( int nParentId, const double ptCen[3
const double ptOn[3], int nRefType) ;
EIN_EXPORT int __stdcall EgtCreateCircleCPEx( int nParentId, const double ptCen[3],
const double ptOn[3], int nSepO, int nIdO, int nRefType) ;
EIN_EXPORT int __stdcall EgtCreateCircle2P( int nParentId, const double ptP1[3],
const double ptP2[3], int nRefType) ;
EIN_EXPORT int __stdcall EgtCreateCircle3P( int nParentId, const double ptP1[3],
const double ptP2[3], const double ptP3[3], int nRefType) ;
EIN_EXPORT int __stdcall EgtCreateArc( int nParentId, const double ptCen[3], double dRad,
@@ -339,13 +321,8 @@ EIN_EXPORT BOOL __stdcall EgtSelectPathObjs( int nId, BOOL bHaltOnFork) ;
EIN_EXPORT int __stdcall EgtDuploNew( int nSouId) ;
EIN_EXPORT BOOL __stdcall EgtDuploCount( int nSouId, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtDuploList( int nSouId, int*& vInd, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtDuploInRawCount( int nSouId, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtDuploWithoutRawList( int*& vInd, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtDuploSetModified( int nSouId) ;
EIN_EXPORT BOOL __stdcall EgtDuploGetModified( int nSouId, BOOL* pbModif) ;
EIN_EXPORT BOOL __stdcall EgtDuploSetLocked( int nDupId) ;
EIN_EXPORT BOOL __stdcall EgtDuploResetLocked( int nDupId) ;
EIN_EXPORT BOOL __stdcall EgtDuploGetLocked( int nDupId, BOOL* pbModif) ;
EIN_EXPORT BOOL __stdcall EgtDuploUpdate( int nSouId) ;
EIN_EXPORT BOOL __stdcall EgtIsDuplo( int nDupId) ;
EIN_EXPORT int __stdcall EgtDuploGetOriginal( int nDupId) ;
@@ -499,7 +476,7 @@ EIN_EXPORT int __stdcall EgtSplitCurve( int nId, int nParts) ;
EIN_EXPORT int __stdcall EgtSplitCurveAtPoint( int nId, const double ptOn[3], int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtModifyCircleCP( int nId, const double ptOn[3], int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtModifyCircle3P( int nId, const double ptP1[3], const double ptP2[3], const double ptP3[3], int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtModifyArcRadius( int nId, double dRad, BOOL bKeepCenter) ;
EIN_EXPORT BOOL __stdcall EgtModifyArcRadius( int nId, double dRad) ;
EIN_EXPORT BOOL __stdcall EgtModifyArcC2P( int nId, const double ptEnd[3], int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtModifyArc3P( int nId, const double ptMid[3], int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtModifyArcByFlip( int nId) ;
@@ -523,12 +500,10 @@ EIN_EXPORT BOOL __stdcall EgtMergeCurvesInCurveCompo( int nId, double dLinTol, B
// GeomDb Surf Modify
EIN_EXPORT BOOL __stdcall EgtInvertSurface( int nId) ;
EIN_EXPORT int __stdcall EgtExplodeSurface( int nId, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtApproxSurface( int nId, double dLinTol) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrAdd( int nId1, int nId2) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrSubtract( int nId1, int nId2) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrIntersect( int nId1, int nId2) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrOffset( int nId, double dDist, int nType) ;
EIN_EXPORT int __stdcall EgtSurfTmToTriangles( int nId, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtSurfTmRemoveFacet( int nId, int nFacet) ;
EIN_EXPORT BOOL __stdcall EgtCutSurfTmPlane( int nId, const double ptOn[3], const double vtN[3], BOOL bSaveOnEq, int nRefType) ;
EIN_EXPORT BOOL __stdcall EgtCutSurfTmClosedCurve( int nSurfId, int nCurveId, BOOL bSaveOnEq) ;
@@ -554,7 +529,6 @@ EIN_EXPORT BOOL __stdcall EgtTextGetItalic( int nId, BOOL* pbItl) ;
// GeomDb Curve Get
EIN_EXPORT BOOL __stdcall EgtCurveDomain( int nId, double* pdStart, double* pdEnd) ;
EIN_EXPORT BOOL __stdcall EgtCurveLength( int nId, double* pdLen) ;
EIN_EXPORT BOOL __stdcall EgtCurveParamAtLength( int nId, double dLen, double* pdU) ;
EIN_EXPORT BOOL __stdcall EgtCurveLengthAtPoint( int nId, const double ptOn[3], double dExtend, double* pdLen) ;
EIN_EXPORT BOOL __stdcall EgtCurveIsClosed( int nId) ;
EIN_EXPORT BOOL __stdcall EgtCurveIsFlat( int nId, BOOL bUseExtrusion, double dToler, double vtN[3], double* pdDist) ;
@@ -567,7 +541,6 @@ EIN_EXPORT BOOL __stdcall EgtCurveSelfIntersCount( int nId, int* pnCount) ;
EIN_EXPORT BOOL __stdcall EgtCurveMinAreaRectangleXY( int nId, int nRefId,
double ptOrig[3], double vtX[3], double vtY[3], double vtZ[3], double* pdDimX, double* pdDimY) ;
EIN_EXPORT int __stdcall EgtClosedCurveClassify( int nId1, int nId2) ;
EIN_EXPORT int __stdcall EgtCurveWithRegionClassify( int nCurveId, int nRegionId) ;
EIN_EXPORT BOOL __stdcall EgtArcRadius( int nId, double* pdRad) ;
EIN_EXPORT BOOL __stdcall EgtArcAngCenter( int nId, double* pdAngDeg) ;
EIN_EXPORT BOOL __stdcall EgtArcDeltaN( int nId, double* pdDeltaN) ;
@@ -575,15 +548,11 @@ EIN_EXPORT BOOL __stdcall EgtArcNormVersor( int nId, int nRefId, double vtNorm[3
EIN_EXPORT BOOL __stdcall EgtCurveCompoCenter( int nId, int nSimpCrv, int nRefId, double ptCen[3]) ;
// GeomDb Surf Get
EIN_EXPORT BOOL __stdcall EgtSurfArea( int nId, double* pdArea) ;
EIN_EXPORT BOOL __stdcall EgtSurfIsClosed( int nId) ;
EIN_EXPORT BOOL __stdcall EgtSurfVolume( int nId, double* pdVol) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrNormVersor( int nId, int nRefId, double vtNorm[3]) ;
EIN_EXPORT BOOL __stdcall EgtSurfFrGrossArea( int nId, double* pdArea) ;
EIN_EXPORT int __stdcall EgtSurfFrChunkCount( int nId) ;
EIN_EXPORT int __stdcall EgtSurfFrChunkSimpleClassify( int nId1, int nChunk1, int nId2, int nChunk2, double dToler) ;
EIN_EXPORT int __stdcall EgtExtractSurfFrChunkLoops( int nId, int nChunk, int nDestGrpId, int* pnCount) ;
EIN_EXPORT int __stdcall EgtSurfTmPartCount( int nId) ;
EIN_EXPORT int __stdcall EgtSurfTmFacetCount( int nId) ;
EIN_EXPORT int __stdcall EgtSurfTmFacetFromTria( int nId, int nT) ;
EIN_EXPORT BOOL __stdcall EgtSurfTmFacetNearestEndPoint( int nId, int nFacet, const double ptNear[3], int nRefId,
@@ -654,9 +623,7 @@ EIN_EXPORT BOOL __stdcall EgtPointSurfTmDist( const double ptP[3], int nId, int
// Geo Inters
EIN_EXPORT BOOL __stdcall EgtLineSurfTmInters( const double ptP[3], const double vtDir[3], int nId, int nRefType,
int*& vFlagInters, double*& vParInters, int* pnCount) ;
EIN_EXPORT int __stdcall EgtPlaneSurfTmInters( const double ptOn[3], const double vtN[3], int nId, int nDestGrpId, int nRefType, double dToler,
int* pnPntCount, int* pnCrvCount, int* pnSrfCount) ;
EIN_EXPORT int __stdcall EgtSurfTmSurfTmInters( int nId1, int nId2, int nDestGrpId, double dToler,
EIN_EXPORT int __stdcall EgtSurfTmSurfTmInters( int nId1, int nId2, int nDestGrpId,
int* pnPntCount, int* pnCrvCount, int* pnSrfCount) ;
// Maximum Filler
@@ -710,10 +677,8 @@ EIN_EXPORT wchar_t* __stdcall EgtGetLastMachMgrErrorString( void) ;
EIN_EXPORT int __stdcall EgtGetMachMgrWarningId( int nInd) ;
EIN_EXPORT wchar_t* __stdcall EgtGetMachMgrWarningString( int nInd) ;
// Machines
EIN_EXPORT BOOL __stdcall EgtGetMachines( wchar_t*& wsMachineNames, wchar_t*& wsMachineDirs) ;
EIN_EXPORT BOOL __stdcall EgtSetCurrMachine( const wchar_t* wsMachineName) ;
EIN_EXPORT BOOL __stdcall EgtGetCurrMachineName( wchar_t*& wsMachineName) ;
EIN_EXPORT BOOL __stdcall EgtGetCurrMachineDir( wchar_t*& wsMachineDir) ;
// Machining Groups
EIN_EXPORT int __stdcall EgtGetMachGroupCount( void) ;
EIN_EXPORT int __stdcall EgtGetFirstMachGroup( void) ;
@@ -722,7 +687,6 @@ EIN_EXPORT int __stdcall EgtGetLastMachGroup( void) ;
EIN_EXPORT int __stdcall EgtGetPrevMachGroup( int nId) ;
EIN_EXPORT BOOL __stdcall EgtGetMachGroupNewName( const wchar_t* wsName, wchar_t*& wsNewName) ;
EIN_EXPORT int __stdcall EgtAddMachGroup( const wchar_t* wsName, const wchar_t* wsMachineName) ;
EIN_EXPORT int __stdcall EgtCopyMachGroup( const wchar_t* wsSouName, const wchar_t* wsName) ;
EIN_EXPORT BOOL __stdcall EgtRemoveMachGroup( int nMGroupId) ;
EIN_EXPORT BOOL __stdcall EgtGetMachGroupName( int nMGroupId, wchar_t*& wsName) ;
EIN_EXPORT BOOL __stdcall EgtGetMachGroupMachineName( int nMGroupId, wchar_t*& wsMachineName) ;
@@ -915,8 +879,6 @@ EIN_EXPORT BOOL __stdcall EgtGetMachiningParamDouble( int nType, double* pdVal)
EIN_EXPORT BOOL __stdcall EgtGetMachiningParamString( int nType, wchar_t*& wsVal) ;
EIN_EXPORT BOOL __stdcall EgtGetMachiningGeometry( int nInd, int* pnId, int* pnSub) ;
EIN_EXPORT BOOL __stdcall EgtIsMachiningEmpty( void) ;
EIN_EXPORT BOOL __stdcall EgtGetMachiningStartPoint( double ptP[3]) ;
EIN_EXPORT BOOL __stdcall EgtGetMachiningEndPoint( double ptP[3]) ;
EIN_EXPORT BOOL __stdcall EgtApplyAllMachinings( BOOL bRecalc, BOOL bStopOnFirstErr, wchar_t*& wsErrList) ;
EIN_EXPORT BOOL __stdcall EgtUpdateAllMachinings( BOOL bStopOnFirstErr, wchar_t*& wsErrList) ;
// Simulation
@@ -941,7 +903,6 @@ EIN_EXPORT int __stdcall EgtGetAxisId( const wchar_t* wsAxis) ;
EIN_EXPORT int __stdcall EgtGetHeadId( const wchar_t* wsHead) ;
EIN_EXPORT int __stdcall EgtGetHeadExitCount( const wchar_t* wsHead) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisInvert( const wchar_t* wsAxis, BOOL* pbInvert) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisOffset( const wchar_t* wsAxis, double* pdOffset) ;
EIN_EXPORT BOOL __stdcall EgtGetAllHeadsNames( wchar_t*& wsNames) ;
EIN_EXPORT BOOL __stdcall EgtGetAllTablesNames( wchar_t*& wsNames) ;
// Machine Calc
@@ -959,9 +920,6 @@ EIN_EXPORT BOOL __stdcall EgtGetOutstrokeInfo( wchar_t*& wsInfo) ;
// Machine Move
EIN_EXPORT BOOL __stdcall EgtSetAxisPos( const wchar_t* wsAxis, double dVal) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisPos( const wchar_t* wsAxis, double* pdVal) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisMin( const wchar_t* wsAxis, double* pdMin) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisMax( const wchar_t* wsAxis, double* pdMax) ;
EIN_EXPORT BOOL __stdcall EgtGetAxisHomePos( const wchar_t* wsAxis, double* pdHome) ;
EIN_EXPORT BOOL __stdcall EgtLoadTool( const wchar_t* wsHead, int nExit, const wchar_t* wsTool) ;
EIN_EXPORT BOOL __stdcall EgtResetHeadSet( const wchar_t* wsHead) ;
EIN_EXPORT BOOL __stdcall EgtSetMachineLook( int nFlag) ;
@@ -979,8 +937,6 @@ EIN_EXPORT BOOL __stdcall EgtSetWinRectAttribs( BOOL bOutline, const int WrCol[4
EIN_EXPORT BOOL __stdcall EgtSetGlobFrameShow( BOOL bShow) ;
EIN_EXPORT BOOL __stdcall EgtSetGridShow( BOOL bShowGrid, BOOL bShowFrame) ;
EIN_EXPORT BOOL __stdcall EgtSetGridGeo( double dSnapStep, int nMinLineSstep, int nMajLineSstep, int nExtSstep) ;
EIN_EXPORT BOOL __stdcall EgtSetGridGeoAdv( double dSnapStep, int nMinLineSstep, int nMajLineSstep,
double dXmin, double dXmax, double dYmin, double dYmax) ;
EIN_EXPORT BOOL __stdcall EgtSetGridColor( const int nMinCol[4], const int nMajCol[4]) ;
EIN_EXPORT BOOL __stdcall EgtResize( int nW, int nH) ;
EIN_EXPORT BOOL __stdcall EgtDraw( void) ;
-2
View File
@@ -34,8 +34,6 @@ extern "C" {
EMK_EXPORT void SetEMkLogger( ILogger* pLogger) ;
// imposta la chiave di protezione
EMK_EXPORT void SetEMkKey( const std::string& sKey) ;
// imposta se chiave hardware di rete
EMK_EXPORT void SetEMkNetHwKey( bool bNetHwKey) ;
}
+4 -13
View File
@@ -1,7 +1,7 @@
//----------------------------------------------------------------------------
// EgalTech 2015-2023
// EgalTech 2015-2021
//----------------------------------------------------------------------------
// File : EMkMachMgr.h Data : 28.10.23 Versione : 2.5j4
// File : EMkMachMgr.h Data : 24.05.21 Versione : 2.3e3
// Contenuto : Dichiarazione della interfaccia IMachMgr.
//
//
@@ -12,9 +12,6 @@
// 17.08.20 DS Aggiunte GetAxisMin e GetAxisMax.
// 10.11.20 DS Portate in interfaccia funzioni di calcolo con vettori di angoli.
// 13.01.21 DS Aggiunte in interfaccia GetCalcHead e GetCalcExit.
// 21.09.22 DS Aggiunta in interfaccia GetAxisOffset.
// 25.08.23 DS Aggiunta in interfaccia CopyMachGroup.
// 28.10.23 DS Aggiunte in interfaccia GetClEntAxesVal, GetToolSetupPosInCurrSetup e GetAllCurrAxesName.
//
//----------------------------------------------------------------------------
@@ -46,7 +43,6 @@ class __declspec( novtable) IMachMgr
virtual int GetWarningId( int nInd) const = 0 ;
virtual std::string GetWarningString( int nInd) const = 0 ;
// Machines
virtual bool GetMachines( STRVECTOR& vsMachineNames, STRVECTOR& vsMachineDirs) const = 0 ;
virtual bool SetCurrMachine( const std::string& sMachineName) = 0 ;
virtual bool GetCurrMachineName( std::string& sMachineName) const = 0 ;
virtual bool GetCurrMachineDir( std::string& sMachineDir) const = 0 ;
@@ -59,7 +55,6 @@ class __declspec( novtable) IMachMgr
virtual int GetPrevMachGroup( int nId) const = 0 ;
virtual bool GetMachGroupNewName( std::string& sName) const = 0 ;
virtual int AddMachGroup( const std::string& sName, const std::string& sMachineName) = 0 ;
virtual int CopyMachGroup( const std::string& sSouName, const std::string& sName) = 0 ;
virtual bool RemoveMachGroup( int nId) = 0 ;
virtual std::string GetMachGroupName( int nId) const = 0 ;
virtual std::string GetMachGroupMachineName( int nId) const = 0 ;
@@ -167,7 +162,6 @@ class __declspec( novtable) IMachMgr
virtual bool ImportSetup( const std::string& sName) = 0 ;
virtual bool VerifyCurrSetup( STRVECTOR& vsErrors) = 0 ;
virtual bool FindToolInCurrSetup( const std::string& sTool) = 0 ;
virtual bool GetToolSetupPosInCurrSetup( const std::string& sTool, std::string& sTcPos) = 0 ;
virtual bool GetToolsInCurrSetupPos( const std::string& sTcPos, STRVECTOR& vsTools) = 0 ;
virtual bool UpdateCurrSetup( void) = 0 ;
virtual bool EraseCurrSetup( void) = 0 ;
@@ -203,7 +197,7 @@ class __declspec( novtable) IMachMgr
virtual bool MdbToBeImported( const std::string& sFile, STRVECTOR& vsMachiningsNames, INTVECTOR& vMachiningsTypes) const = 0 ;
virtual bool MdbImport( const std::string& sFile, const STRVECTOR& vsMachiningsToImport, const STRVECTOR& vsMachiningsNames,
STRVECTOR& vsImported) = 0 ;
// Operations : general
// Operations : general
virtual int GetOperationCount( void) const = 0 ;
virtual int GetFirstOperation( void) const = 0 ;
virtual int GetNextOperation( int nId) const = 0 ;
@@ -266,9 +260,8 @@ class __declspec( novtable) IMachMgr
virtual bool GetMachiningEndPoint( Point3d& ptEnd) const = 0 ;
// CL Entities Interrogations
virtual bool GetClEntMove( int nEntId, int& nMove) const = 0 ;
virtual bool GetClEntFlag( int nEntId, int& nFlag, int& nFlag2) const = 0 ;
virtual bool GetClEntFlag( int nEntId, int& nFlag) const = 0 ;
virtual bool GetClEntIndex( int nEntId, int& nIndex) const = 0 ;
virtual bool GetClEntAxesVal( int nEntId, DBLVECTOR& vAxes) const = 0 ;
// Simulation
virtual bool SimInit( void) = 0 ;
virtual bool SimStart( bool bFirst) = 0 ;
@@ -287,7 +280,6 @@ class __declspec( novtable) IMachMgr
// Machine Calc
virtual bool SetCalcTable( const std::string& sTable) = 0 ;
virtual bool SetCalcTool( const std::string& sTool, const std::string& sHead, int nExit) = 0 ;
virtual bool GetAllCurrAxesName( STRVECTOR& vAxName) const = 0 ;
virtual bool SetRotAxisBlock( const std::string& sAxis, double dVal) = 0 ;
virtual bool GetRotAxisBlocked( int nInd, std::string& sAxis, double& dVal) const = 0 ;
virtual bool GetCalcTool( std::string& sTool) const = 0 ;
@@ -321,7 +313,6 @@ class __declspec( novtable) IMachMgr
virtual bool GetAxisToken( const std::string& sAxis, std::string& sToken) const = 0 ;
virtual bool GetAxisType( const std::string& sAxis, bool& bLinear) const = 0 ;
virtual bool GetAxisInvert( const std::string& sAxis, bool& bInvert) const = 0 ;
virtual bool GetAxisOffset( const std::string& sAxis, double& dOffset) const = 0 ;
virtual bool SetAxisPos( const std::string& sAxis, double dVal, double* pdNewVal = nullptr) = 0 ;
virtual bool GetAxisPos( const std::string& sAxis, double& dVal) const = 0 ;
virtual bool GetAxisMin( const std::string& sAxis, double& dMin) const = 0 ;

Some files were not shown because too many files have changed in this diff Show More