- in lapJoint -> SawPlusChain piccole modifiche
- in mortise -> AddCleanCornersMachining resa locale variabile erroneamente dichiarata globale
This commit is contained in:
+25
-18
@@ -4715,13 +4715,13 @@ function SawPlusChain.GetSideFaces( Proc)
|
||||
if ( not bIsFaceToMachineTheLargest and i < #FacesAdjacentToBottom) or
|
||||
( bIsFaceToMachineTheLargest and i > 2) then
|
||||
table.insert( SideFaces, FacesAdjacentToBottom[i])
|
||||
SideFaces[ #SideFaces].Id = FacesAdjacentToBottom[i].Id
|
||||
SideFaces[ #SideFaces].Width = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Width
|
||||
SideFaces[ #SideFaces].Height = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Height
|
||||
SideFaces[ #SideFaces].Elevation = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Elevation
|
||||
SideFaces[ #SideFaces].VtN = Proc.Face[FacesAdjacentToBottom[i].Id + 1].VtN
|
||||
if SideFaces[ #SideFaces].Height > SideFaces[ #SideFaces].Width then
|
||||
SideFaces[ #SideFaces].Height, SideFaces[ #SideFaces].Width = SideFaces[ #SideFaces].Width, SideFaces[ #SideFaces].Height
|
||||
SideFaces[#SideFaces].Id = FacesAdjacentToBottom[i].Id
|
||||
SideFaces[#SideFaces].Width = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Width
|
||||
SideFaces[#SideFaces].Height = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Height
|
||||
SideFaces[#SideFaces].Elevation = Proc.Face[FacesAdjacentToBottom[i].Id + 1].Elevation
|
||||
SideFaces[#SideFaces].VtN = Proc.Face[FacesAdjacentToBottom[i].Id + 1].VtN
|
||||
if SideFaces[#SideFaces].Height > SideFaces[#SideFaces].Width then
|
||||
SideFaces[#SideFaces].Height, SideFaces[#SideFaces].Width = SideFaces[ #SideFaces].Width, SideFaces[ #SideFaces].Height
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -4793,20 +4793,10 @@ function SawPlusChain.GetHorizontalSteps( Machining)
|
||||
return HorizontalSteps
|
||||
end
|
||||
|
||||
|
||||
function SawPlusChain.CalculateLeadInOut( Proc, Machining)
|
||||
-- TODO implementare le funzioni di Tool Collision Avoidance (vedi wiki e FacesBysaw -> CalcLeadInOutPerpGeom)
|
||||
|
||||
-- si determina se l'inizio o la fine della lavorazione sono chiusi e l'eventuale riduzione da applicare
|
||||
function SawPlusChain.IsStartOrEndClosed( Proc, Machining)
|
||||
local bIsStartClosed = false
|
||||
local bIsEndClosed = false
|
||||
local bIsMortising = ( Machining.Type == MCH_OY.MORTISING)
|
||||
local dAddLengthToReduce = 0
|
||||
if bIsMortising then
|
||||
dAddLengthToReduce = Machining.Tool.Diameter / 2
|
||||
else
|
||||
dAddLengthToReduce = sqrt( Machining.Depth * Machining.Tool.Diameter - Machining.Depth * Machining.Depth)
|
||||
end
|
||||
if #( Proc.Pocket.SideFaces) == 2 then
|
||||
bIsStartClosed = true
|
||||
bIsEndClosed = true
|
||||
@@ -4830,6 +4820,23 @@ function SawPlusChain.CalculateLeadInOut( Proc, Machining)
|
||||
end
|
||||
end
|
||||
|
||||
return bIsStartClosed, bIsEndClosed
|
||||
end
|
||||
|
||||
|
||||
function SawPlusChain.CalculateLeadInOut( Proc, Machining)
|
||||
-- TODO implementare le funzioni di Tool Collision Avoidance (vedi wiki e FacesBysaw -> CalcLeadInOutPerpGeom)
|
||||
|
||||
-- si determina se l'inizio o la fine della lavorazione sono chiusi e l'eventuale riduzione da applicare
|
||||
local bIsStartClosed, bIsEndClosed = SawPlusChain.IsStartOrEndClosed( Proc, Machining)
|
||||
local bIsMortising = ( Machining.Type == MCH_OY.MORTISING)
|
||||
local dAddLengthToReduce = 0
|
||||
if bIsMortising then
|
||||
dAddLengthToReduce = Machining.Tool.Diameter / 2
|
||||
else
|
||||
dAddLengthToReduce = sqrt( Machining.Depth * Machining.Tool.Diameter - Machining.Depth * Machining.Depth)
|
||||
end
|
||||
|
||||
local LeadIn = {}
|
||||
local LeadOut = {}
|
||||
LeadIn.StartAddLength = 0
|
||||
|
||||
@@ -128,7 +128,7 @@ end
|
||||
local nFaceUse = BL.GetNearestParalOpposite( vtN)
|
||||
EgtSetMachiningParam( MCH_MP.FACEUSE, nFaceUse)
|
||||
-- applico il parametro plunge, che setta la lavorazione per affondare solamente, senza lavorare tutto il contorno; 1: solo lato iniziale, 2: solo lato finale, 3: entrambi
|
||||
sNotes = 'Plunge=3;'
|
||||
local sNotes = 'Plunge=3;'
|
||||
EgtSetMachiningParam( MCH_MP.USERNOTES, sNotes)
|
||||
-- imposto angolo 3° asse rot
|
||||
local vtOrtho = BL.GetVersRef( nFaceUse)
|
||||
|
||||
Reference in New Issue
Block a user