DataWall :

- correzioni varie.
This commit is contained in:
DarioS
2021-06-14 17:04:37 +02:00
parent 4f94b2de3a
commit 4b10910a00
2 changed files with 20 additions and 9 deletions
+15 -7
View File
@@ -1198,10 +1198,12 @@ local function AddMillings( sMilling, vFace, Proc, nRawId, b3Raw, nConeCut, nAdd
local dSal = EgtIf( ( vFace[i].Type & 2) ~= 0, vFace[i].Whisk - vFace[i].Len, 0)
local dEal = 0
local OrigI = i
local LastJ
i = i + 1
local j = EgtIf( i <= #vFace, i, EgtIf( bAllType4 or not bClosed, nil, 1))
while j and ( ( vFace[j].Type & 1) ~= 0 or vFace[j].Type == 4) and abs( vFace[j].SideAng - vFace[OrigI].SideAng) < 0.1 do
table.insert( vGeom, { Proc.Id, vFace[j].Fac})
LastJ = j
dEal = EgtIf( ( vFace[j].Type & 1) ~= 0, vFace[j].Whisk - vFace[j].Len, 0)
if ( vFace[j].Type & 1) ~= 0 then
break
@@ -1213,14 +1215,20 @@ local function AddMillings( sMilling, vFace, Proc, nRawId, b3Raw, nConeCut, nAdd
if #vFace == 1 then
dSal = -dMillDiam / 2
dEal = -dMillDiam / 2
-- se lavorazione completa su faccia singola
elseif vFace[OrigI].Type == 4 then
if vFace[OrigI].PrevAng < -30 then
dSal = -dMillDiam / 2
-- altrimenti va verificato
else
-- se lavorazione completa su faccia iniziale
if vFace[OrigI].Type == 4 then
if vFace[OrigI].PrevAng < -30 then
dSal = -dMillDiam / 2
end
end
local OrigK = EgtIf( OrigI < #vFace, OrigI + 1, EgtIf( bClosed, 1, nil))
if OrigK and vFace[OrigK].PrevAng < -30 then
dEal = -dMillDiam / 2
-- se lavorazione completa su faccia finale
if LastJ and vFace[LastJ].Type == 4 then
local OrigK = EgtIf( LastJ < #vFace, LastJ + 1, EgtIf( bClosed, 1, nil))
if OrigK and vFace[OrigK].PrevAng < -30 then
dEal = -dMillDiam / 2
end
end
end
-- se non devo scaricare l'angolo
+5 -2
View File
@@ -1024,7 +1024,10 @@ local function MakeByChainSaw( Proc, nFacet, nRawId, b3Raw, dElev, dH, dV)
-- Calcolo uso faccia
local nFaceUse = WL.GetNearestParalOpposite( vtN)
-- Calcolo angolo 3° asse rot (da direz. utensile)
local d3RotAng = 180
local sRot3Ang = 'A1=180'
if WD.GetChainSawBlockedAxis then
sRot3Ang = WD.GetChainSawBlockedAxis( 1)
end
-- Lati chiusi
local bOpenStart = false
local bOpenEnd = false
@@ -1052,7 +1055,7 @@ local function MakeByChainSaw( Proc, nFacet, nRawId, b3Raw, dElev, dH, dV)
EgtSetMachiningParam( MCH_MP.STARTADDLEN, EgtIf( bOpenStart, 0, - dSawWidth / 2))
EgtSetMachiningParam( MCH_MP.ENDADDLEN, EgtIf( bOpenEnd, 0, - dSawWidth / 2))
-- imposto angolo 3° asse rot
EgtSetMachiningParam( MCH_MP.BLOCKEDAXIS, 'A1=' .. EgtNumToString( d3RotAng))
EgtSetMachiningParam( MCH_MP.BLOCKEDAXIS, sRot3Ang)
-- imposto offset radiale
local dOffs = ( i - 1) * dStep
EgtSetMachiningParam( MCH_MP.OFFSR, dOffs)