28ae97ae20
- modificati prototipi per funzioni di creazione Zmap per versioni a 32Bit.
116 lines
7.7 KiB
C++
116 lines
7.7 KiB
C++
//----------------------------------------------------------------------------
|
|
// EgalTech 2015-2024
|
|
//----------------------------------------------------------------------------
|
|
// File : EGkVolZmap.h Data : 22.04.24 Versione : 2.6d4
|
|
// Contenuto : Dichiarazione della interfaccia IVolZmap.
|
|
//
|
|
//
|
|
//
|
|
// Modifiche : 22.01.15 DS Creazione modulo.
|
|
// 12.09.23 DS Aggiunto metodo IsTriDexel.
|
|
// 09.03.24 DS Aggiunti SetShowEdges e GetShowEdges.
|
|
// 10.06.25 RE Aggiunte funzioni per Offset di superfici TriMesh chiuse
|
|
// 04.07.25 RE Aggiunte funzioni per Thickening Offset di superfici TriMesh generiche
|
|
//
|
|
//----------------------------------------------------------------------------
|
|
|
|
#pragma once
|
|
|
|
#include "/EgtDev/Include/EGkGeoObj.h"
|
|
#include "/EgtDev/Include/EGkCurveComposite.h"
|
|
#include "/EgtDev/Include/EGkSurfFlatRegion.h"
|
|
#include "/EgtDev/Include/EGkSurfTriMeshAux.h"
|
|
|
|
//----------------------------------------------------------------------------
|
|
class __declspec( novtable) IVolZmap : public IGeoObj
|
|
{
|
|
public : // IGeoObj
|
|
IVolZmap* Clone( void) const override = 0 ;
|
|
public :
|
|
virtual bool CopyFrom( const IGeoObj* pGObjSrc) = 0 ;
|
|
virtual bool Clear( void) = 0 ;
|
|
virtual bool Create( const Point3d& ptO, double dDimX, double dDimY, double dDimZ, double dStep, bool bTriDex, int* nError = nullptr) = 0 ;
|
|
virtual bool CreateEmpty( const Point3d& ptO, double dDimX, double dDimY, double dDimZ, double dStep, bool bTriDex, int* nError = nullptr) = 0 ;
|
|
virtual bool CreateFromFlatRegion( const ISurfFlatRegion& Surf, double dDimZ, double dStep, bool bTriDex, int* nError = nullptr) = 0 ;
|
|
virtual bool CreateFromTriMesh( const ISurfTriMesh& Surf, double dStep, bool bTriDex, double dExtraBox = 0, int* nError = nullptr) = 0 ;
|
|
virtual int GetBlockCount( void) const = 0 ;
|
|
virtual int GetBlockUpdatingCounter( int nBlock) const = 0 ;
|
|
virtual bool GetBlockTriangles( int nBlock, TRIA3DEXVECTOR& vTria) const = 0 ;
|
|
virtual ISurfTriMesh* GetSurfTriMesh( void) 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 void SetShowEdges( bool bShow) = 0 ;
|
|
virtual bool GetShowEdges( void) const = 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 SetAdvTool( const std::string& sToolName,
|
|
double dH, double dR, double dTipH, double dTipR, double dCornR, double dCutterH, int nFlag, bool bFirst) = 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 bool SetAdditiveTool( const std::string& sToolName,
|
|
double dH, double dR, double dRc, int nFlag, bool bFirst) = 0 ;
|
|
virtual int GetToolCount( void) const = 0 ;
|
|
virtual bool SetCurrTool( int nCurrTool) = 0 ;
|
|
virtual bool ResetTools( 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,
|
|
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 CDeBox( const Frame3d& frBox, const Vector3d& vtDiag, double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeSphere( const Point3d& ptCenter, double dRad, double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeCylinder( const Frame3d& frCyl, double dR, double dH, double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeConeFrustum( const Frame3d& frCone, double dRadBot, double dRadTop, double dHeight,
|
|
double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeRectPrismoid( const Frame3d& frPrismoid, double dLenghtBaseX, double dLenghtBaseY,
|
|
double dLenghtTopX, double dLenghtTopY, double dHeight,
|
|
double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeTorus( const Frame3d& frTorus, double dRadMax, double dRadMin,
|
|
double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool CDeSurfTm( const ISurfTriMesh& tmSurf, double dSafeDist, bool bPrecise = false) const = 0 ;
|
|
virtual bool Cut( const Plane3d& plPlane) = 0 ;
|
|
virtual bool Compact( void) = 0 ;
|
|
virtual int GetPartCount( void) const = 0 ;
|
|
virtual bool GetPartVolume( int nPart, double& dVol) const = 0 ;
|
|
virtual bool GetPartLocalBBox( int nPart, BBox3d& b3Loc, int nFlag = BBF_STANDARD) const = 0 ;
|
|
virtual bool GetPartBBox( int nPart, const Frame3d& frRef, BBox3d& b3Ref, int nFlag = BBF_STANDARD) const = 0 ;
|
|
virtual IVolZmap* ClonePart( int nPart) const = 0 ;
|
|
virtual bool RemovePart( int nPart) = 0 ;
|
|
virtual int GetPartMinDistFromPoint( const Point3d& ptP) const = 0 ;
|
|
virtual bool AddSurfTm( const ISurfTriMesh* pStm) = 0 ;
|
|
virtual bool SubtractSurfTm( const ISurfTriMesh* pStm) = 0 ;
|
|
virtual bool MakeUniform( double dToler, bool bIsExtensionFirst = true, int nToolNum = 0) = 0 ;
|
|
virtual bool RemoveFins( const Vector3d& vtDir, double dThick) = 0 ;
|
|
virtual bool Offset( double dOffs, int nType) = 0 ;
|
|
} ;
|
|
|
|
//-----------------------------------------------------------------------------
|
|
inline IVolZmap* CreateVolZmap( void)
|
|
{ return (static_cast<IVolZmap*>( CreateGeoObj( VOL_ZMAP))) ; }
|
|
inline IVolZmap* CloneVolZmap( const IGeoObj* pGObj)
|
|
{ if ( pGObj == nullptr || pGObj->GetType() != VOL_ZMAP)
|
|
return nullptr ;
|
|
return (static_cast<IVolZmap*>(pGObj->Clone())) ; }
|
|
inline const IVolZmap* GetVolZmap( const IGeoObj* pGObj)
|
|
{ if ( pGObj == nullptr || pGObj->GetType() != VOL_ZMAP)
|
|
return nullptr ;
|
|
return (static_cast<const IVolZmap*>(pGObj)) ; }
|
|
inline IVolZmap* GetVolZmap( IGeoObj* pGObj)
|
|
{ if ( pGObj == nullptr || pGObj->GetType() != VOL_ZMAP)
|
|
return nullptr ;
|
|
return (static_cast<IVolZmap*>(pGObj)) ; }
|