EgtGeomKernel 1.8j4 :
- aggiunta classe Polygon3d (da EgtExchange) - razionalizzata classe Plane3d - corretta funzione IntersLineTria.
This commit is contained in:
+3
-3
@@ -44,7 +44,7 @@ Triangulate::Make( const PolyLine& PL, PNTVECTOR& vPt, INTVECTOR& vTr)
|
||||
return false ;
|
||||
// determino il piano ottimale di proiezione e il relativo senso di rotazione
|
||||
bool bCCW ;
|
||||
if ( ! CalcProjPlane( plPlane.vtN, m_nPlane, bCCW))
|
||||
if ( ! CalcProjPlane( plPlane.GetVersN(), m_nPlane, bCCW))
|
||||
return false ;
|
||||
// riempio il vettore con i vertici del poligono da triangolare
|
||||
vPt.clear() ;
|
||||
@@ -103,7 +103,7 @@ Triangulate::Make( const POLYLINEVECTOR& vPL, PNTVECTOR& vPt, INTVECTOR& vTr)
|
||||
return false ;
|
||||
// determino il piano ottimale di proiezione e il relativo senso di rotazione
|
||||
bool bCCW ;
|
||||
if ( ! CalcProjPlane( plExtPlane.vtN, m_nPlane, bCCW))
|
||||
if ( ! CalcProjPlane( plExtPlane.GetVersN(), m_nPlane, bCCW))
|
||||
return false ;
|
||||
// verifico le altre polilinee
|
||||
for ( int i = 1 ; i < int( vPL.size()) ; ++i) {
|
||||
@@ -111,7 +111,7 @@ Triangulate::Make( const POLYLINEVECTOR& vPL, PNTVECTOR& vPt, INTVECTOR& vTr)
|
||||
double dArea ;
|
||||
Plane3d plPlane ;
|
||||
if ( ! vPL[i].IsClosedAndFlat( plPlane, dArea, 50 * EPS_SMALL) ||
|
||||
! AreOppositeVectorApprox( plExtPlane.vtN, plPlane.vtN))
|
||||
! AreOppositeVectorApprox( plExtPlane.GetVersN(), plPlane.GetVersN()))
|
||||
return false ;
|
||||
}
|
||||
// se non CCW inverto tutte le polilinee
|
||||
|
||||
Reference in New Issue
Block a user