EgtGeomKernel 1.5f1 :

- aggiunta entità testo (con font Nfe e di sistema)
- in tutte le rotate ora l'angolo è in gradi
- aggiunta trasformazione Shear (scorrimento)
- aggiunta trsformazione LocToLoc
- Set/GetInfo specializzate per i diversi tipi di informazioni
- Copy e Relocate con possibilità di indicare l'entità di riferimento rispetto a cui inserire
- aggiunte trasformazioni a PolyLine.
This commit is contained in:
Dario Sassi
2014-06-03 13:19:54 +00:00
parent a52d73aa7a
commit 41a38fef3b
44 changed files with 3257 additions and 248 deletions
+40
View File
@@ -20,6 +20,7 @@
#include "NgeWriter.h"
#include "NgeReader.h"
#include "GeoObjRW.h"
#include "/EgtDev/Include/EGkCurveArc.h"
#include "/EgtDev/Include/EGkGdbFunct.h"
#include "/EgtDev/Include/EGnStringUtils.h"
#include <new>
@@ -263,6 +264,35 @@ GdbGeo::Mirror( const Point3d& ptOn, const Vector3d& vtNorm)
return m_pGeoObj->Mirror( ptOn, vtNorm) ;
}
//----------------------------------------------------------------------------
bool
GdbGeo::Shear( const Point3d& ptOn, const Vector3d& vtNorm, const Vector3d& vtDir, double dCoeff)
{
if ( m_pGeoObj == nullptr)
return false ;
// verifiche per arco
if ( m_pGeoObj->GetType() == CRV_ARC) {
// ricavo puntatore ad arco
ICurveArc* pArc = GetCurveArc( m_pGeoObj) ;
// se l'arco non è piatto o il piano di scorrimento non coincide con quello dell'arco
if ( ! pArc->IsFlat() ||
! ( AreSameVectorExact( pArc->GetNormVersor(), vtNorm) ||
AreOppositeVectorExact( pArc->GetNormVersor(), vtNorm))) {
// trasformo in curva di Bezier (semplice o composta)
ICurve* pCrvNew ;
if ( ! ArcToBezierCurve( GetCurve( m_pGeoObj), pCrvNew))
return false ;
// elimino l'arco e lo sostituisco con la curva di Bezier
delete m_pGeoObj ;
m_pGeoObj = pCrvNew ;
}
}
// eseguo scorrimento
return m_pGeoObj->Shear( ptOn, vtNorm, vtDir, dCoeff) ;
}
//----------------------------------------------------------------------------
bool
GdbGeo::ToGlob( const Frame3d& frRef)
@@ -283,6 +313,16 @@ GdbGeo::ToLoc( const Frame3d& frRef)
return m_pGeoObj->ToLoc( frRef) ;
}
//----------------------------------------------------------------------------
bool
GdbGeo::LocToLoc( const Frame3d& frOri, const Frame3d& frDest)
{
if ( m_pGeoObj == nullptr)
return false ;
return m_pGeoObj->LocToLoc( frOri, frDest) ;
}
//----------------------------------------------------------------------------
bool
GdbGeo::OnSetMaterial( void)