EgtGeomKernel 1.8g1 :

- modifiche a Zmap
- aggiunto clamp a ratio di font
- migliorata ricerca nomi con *.
This commit is contained in:
Dario Sassi
2017-08-01 07:59:56 +00:00
parent e162483df8
commit 76d94d6194
11 changed files with 1840 additions and 1001 deletions
+36 -8
View File
@@ -179,6 +179,15 @@ VolZmap::SubtractIntervals( unsigned int nGrid, unsigned int nI, unsigned int nJ
if ( nGrid == 0) {
/*INTVECTOR nXBlock ;
INTVECTOR nYBlock ;
nXBlock.emplace_back( min( nI / m_nDexNumPBlock, m_nFracLin[0] - 1)) ;
nYBlock.emplace_back( min( nJ / m_nDexNumPBlock, m_nFracLin[1] - 1)) ;
if ( nI % N_DEXBLOCK == 0 && nXBlock[0] > 0)
nXBlock.emplace_back( nXBlock[0] - 1) ;
if ( nJ % N_DEXBLOCK == 0 && nYBlock[0] > 0)
nYBlock.emplace_back( nYBlock[0] - 1) ;*/
int nXStop = 1 ;
int nYStop = 1 ;
@@ -216,6 +225,15 @@ VolZmap::SubtractIntervals( unsigned int nGrid, unsigned int nI, unsigned int nJ
else if ( nGrid == 1) {
/*INTVECTOR nYBlock ;
INTVECTOR nZBlock ;
nYBlock.emplace_back( min( nI / m_nDexNumPBlock, m_nFracLin[1] - 1)) ;
nZBlock.emplace_back( min( nJ / m_nDexNumPBlock, m_nFracLin[2] - 1)) ;
if ( nI % N_DEXBLOCK == 0 && nYBlock[0] > 0)
nYBlock.emplace_back( nYBlock[0] - 1) ;
if ( nJ % N_DEXBLOCK == 0 && nZBlock[0] > 0)
nZBlock.emplace_back( nZBlock[0] - 1) ;*/
int nYStop = 1 ;
int nZStop = 1 ;
@@ -253,6 +271,15 @@ VolZmap::SubtractIntervals( unsigned int nGrid, unsigned int nI, unsigned int nJ
else if ( nGrid == 2) {
/*INTVECTOR nXBlock ;
INTVECTOR nZBlock ;
nXBlock.emplace_back( min( nJ / m_nDexNumPBlock, m_nFracLin[0] - 1)) ;
nZBlock.emplace_back( min( nI / m_nDexNumPBlock, m_nFracLin[2] - 1)) ;
if ( nJ % N_DEXBLOCK == 0 && nXBlock[0] > 0)
nXBlock.emplace_back( nXBlock[0] - 1) ;
if ( nI % N_DEXBLOCK == 0 && nZBlock[0] > 0)
nZBlock.emplace_back( nZBlock[0] - 1) ;*/
int nXStop = 1 ;
int nZStop = 1 ;
@@ -4096,7 +4123,7 @@ VolZmap::CompCyl_Milling( unsigned int nGrid, const Point3d& ptS, const Point3d&
for ( unsigned int i = nStartI ; i <= nEndI ; ++ i) {
for ( unsigned int j = nStartJ ; j <= nEndJ ; ++ j) {
Point3d ptC( ( i + 0.5) * m_dStep, ( j + 0.5) * m_dStep, 0) ;
Point3d ptInt1, ptInt2 ;
@@ -4316,9 +4343,9 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
double dSqIndet = EPS_SMALL * EPS_SMALL ;
// Variabili booleane per i tappi
Vector3d vtUmv = vtMove ; vtUmv.Normalize() ;
// Variabili booleane per i tappi
bool bConeT = ( abs( vtToolDir * vtUmv) > EPS_SMALL ? true : bTapT) ;
bool bConeB = ( abs( vtToolDir * vtUmv) > EPS_SMALL ? true : bTapB) ;
bool bElpsB = ( abs( vtToolDir * vtUmv) > EPS_SMALL ? true : bTapB) ;
@@ -4328,10 +4355,11 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
Vector3d vtNmin, vtNmax ;
if ( dRatio * dTan <= 1) {
for ( unsigned int i = nStartI ; i <= nEndI ; ++ i) {
for ( unsigned int j = nStartJ ; j <= nEndJ ; ++ j) {
double dX = ( i + 0.5) * m_dStep ;
double dY = ( j + 0.5) * m_dStep ;
@@ -4407,7 +4435,7 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
// Intersezione con la prima faccia
if ( abs( vtPoly * vtNs) > COS_ORTO_ANG_ZERO) {
if ( dLenY * ptPoly1.x >= dLenX * ptPoly1.y &&
dLenY * ( ptPoly1.x - dDeltaX) <= dLenX * ptPoly1.y &&
dLenY * ( ptPoly1.x - dDeltaX) <= dLenX * ( ptPoly1.y - dDeltaY) &&
dDeltaX * ptPoly1.y >= dDeltaY * ptPoly1.x &&
dDeltaX * ( ptPoly1.y - dLenY) <= dDeltaY * ( ptPoly1.x - dLenX)) {
@@ -4415,11 +4443,11 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
vtN1 = - vtNs ;
++ nIntNum ;
}
}
}
// Intersezione con la seconda faccia
if ( abs( vtPoly * vtNd) > COS_ORTO_ANG_ZERO) {
if ( dLenY * ptPoly2.x >= dLenX * ptPoly2.y &&
dLenY * ( ptPoly2.x - dDeltaX) <= dLenX * ptPoly2.y &&
dLenY * ( ptPoly2.x - dDeltaX) <= dLenX * ( ptPoly2.y - dDeltaY) &&
dDeltaX * ptPoly2.y >= dDeltaY * ptPoly2.x &&
dDeltaX * ( ptPoly2.y - dLenY) <= dDeltaY * ( ptPoly2.x - dLenX)) {
@@ -4549,7 +4577,7 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
vtNmin = vtN2 ;
vtNmax = vtN1 ;
}
SubtractIntervals( nGrid, i, j, dMin, dMax, vtNmin, vtNmax) ;
}
@@ -4605,7 +4633,7 @@ VolZmap::CompConus_Milling( unsigned int nGrid, const Point3d & ptS, const Point
for ( unsigned int i = nStartI ; i <= nEndI ; ++ i) {
for ( unsigned int j = nStartJ ; j <= nEndJ ; ++ j) {
double dX = ( i + 0.5) * m_dStep ;
double dY = ( j + 0.5) * m_dStep ;