diff --git a/VolZmapVolume.cpp b/VolZmapVolume.cpp index 0f238e3..d778a17 100644 --- a/VolZmapVolume.cpp +++ b/VolZmapVolume.cpp @@ -2610,7 +2610,14 @@ VolZmap::MillingGeneralMotionStep( const Point3d& ptPs, const Vector3d& vtDs, co // Calcolo angoli di rotazione utensile longitudinale e trasversale rispetto al movimento per eventuale suddivisione double dAlongAngDeg, dAcrossAngDeg ; - GetAlongAcrossRotation( vtDs, vtDe, ptPe - ptPs, dAlongAngDeg, dAcrossAngDeg) ; + if ( m_vTool[m_nCurrTool].GetRadius() < 40) + GetAlongAcrossRotation( vtDs, vtDe, ptPe - ptPs, dAlongAngDeg, dAcrossAngDeg) ; + else { + Vector3d vtAxis = vtDs ^ vtDe ; + GetAlongAcrossRotation( vtDs, vtDe, vtAxis, dAlongAngDeg, dAcrossAngDeg) ; + swap( dAlongAngDeg, dAcrossAngDeg) ; + } + // Calcolo numero degli step di movimento int nStepCnt = int( max( { abs( dAlongAngDeg) / ANG_ALONG_STEP, abs( dAcrossAngDeg) / ANG_ACROSS_STEP, 1.})) ; @@ -2719,7 +2726,7 @@ VolZmap::MillingGeneralMotionStep( const Point3d& ptPs, const Vector3d& vtDs, co InitializePointsAndVectors( ptSti, ptEni, vtDSi, vtDEi, ptLs, ptLe, vtLs, vtLe) ; // Standard รจ multithread - constexpr bool MULTITHREAD = false ; + constexpr bool MULTITHREAD = true ; if ( MULTITHREAD) { // Ciclo sulle mappe vector> vRes( m_nMapNum) ;