EgtGraphics 2.2c3 :

- aggiunta gestione superfici di Bezier.
This commit is contained in:
Dario Sassi
2020-03-26 11:52:42 +00:00
parent 43e1db36fa
commit e58b19da45
4 changed files with 50 additions and 1 deletions
+4 -1
View File
@@ -27,6 +27,7 @@
#include "/EgtDev/Include/EGkCurveComposite.h"
#include "/EgtDev/Include/EGkSurfTriMesh.h"
#include "/EgtDev/Include/EGkSurfFlatRegion.h"
#include "/EgtDev/Include/EGkSurfBezier.h"
#include "/EgtDev/Include/EGkVolZmap.h"
#include "/EgtDev/Include/EGkExtText.h"
#include "/EgtDev/Include/EGkExtDimension.h"
@@ -227,6 +228,7 @@ Scene::DrawGeoObj( const IGdbIterator& iIter, int nPass, const MdStMkCol& siObj)
switch ( nGeoType) {
case SRF_TRIMESH : pSTM = GetSurfTriMesh( pGeoObj) ; break ;
case SRF_FLATRGN : pSTM = GetSurfFlatRegion( pGeoObj)->GetAuxSurf() ; break ;
case SRF_BEZIER : pSTM = GetSurfBezier( pGeoObj)->GetAuxSurf() ; break ;
}
if ( pSTM != nullptr && pSTM->GetTriangleCount() > N_MIN_TRIA_NEWWAY)
bNewWay = true ;
@@ -318,7 +320,7 @@ Scene::DrawGeoObj( const IGdbIterator& iIter, int nPass, const MdStMkCol& siObj)
pCurve->GetThickness( dTh) && abs( dTh) > EPS_SMALL) {
// segmenti di raccordo
PNTVECTOR vPnt ;
bool bDense = ( nGeoType == CRV_ARC || nGeoType == CRV_BEZ) ;
bool bDense = ( nGeoType == CRV_ARC || nGeoType == CRV_BEZIER) ;
if ( CalcConnectingLines( PL, dTh * vtExtr, bDense, vPnt))
pGraphics->AddLines( vPnt) ;
// percorso traslato
@@ -333,6 +335,7 @@ Scene::DrawGeoObj( const IGdbIterator& iIter, int nPass, const MdStMkCol& siObj)
switch (nGeoType) {
case SRF_TRIMESH : pSTM = GetSurfTriMesh( pGeoObj) ; break ;
case SRF_FLATRGN : pSTM = GetSurfFlatRegion( pGeoObj)->GetAuxSurf() ; break ;
case SRF_BEZIER : pSTM = GetSurfBezier( pGeoObj)->GetAuxSurf() ; break ;
}
if ( pSTM == nullptr)
return false ;