- varie modifiche ai tagli di lama per DownUp, caso solo 2d

- in FaceData.GetEdgesInfo si scrivono anche i ptStart e ptEnd; IsFaceRhomboid diventa IsFaceParallelogram
- in BeamLib aggiunta IsEdgeOnBox
This commit is contained in:
luca.mazzoleni
2025-11-03 16:29:12 +01:00
parent 2d1abbb3cc
commit 7b4673acef
5 changed files with 102 additions and 46 deletions
+6 -5
View File
@@ -260,6 +260,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
end
local dRadialStepSpan = OptionalParameters.dRadialStepSpan
local sUserNotes = OptionalParameters.sUserNotes or ''
local bAllowEntryFromInternalEdge = OptionalParameters.bAllowEntryFromInternalEdge or false
-- lunghezze, direzioni e punti caratteristici della lavorazione e del lato lavorato
Cutting.dEdgeLength = EdgeToMachine.dLength
@@ -278,7 +279,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
local dDownUpElevation = dDepthToMachine
-- si determina se il taglio è fattibile e il modo di lavorare della lama
Cutting.bIsApplicable, Cutting.sBladeEngagement, dDownUpElevation = MachiningLib.GetBladeEngagement( FaceToMachine, EdgeToMachine, Part.b3Raw, TOOLS[nToolIndex])
Cutting.bIsApplicable, Cutting.sBladeEngagement, dDownUpElevation = MachiningLib.GetBladeEngagement( FaceToMachine, EdgeToMachine, Part.b3Raw, TOOLS[nToolIndex], bAllowEntryFromInternalEdge)
-- orientamento non raggiungibile o elevazione eccessiva per DownUp: non applicabile
if not Cutting.bIsApplicable
@@ -299,7 +300,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
ToolSearchParameters.bForceLongcutBlade = bForceLongcutBlade
ToolSearchParameters.FaceToMachine = FaceToMachine
ToolSearchParameters.EdgeToMachine = EdgeToMachine
ToolSearchParameters.b3Raw = Part.b3Raw
ToolSearchParameters.b3Part = Part.b3Part
local ToolInfo = MachiningLib.FindBlade( Proc, ToolSearchParameters)
Cutting.nToolIndex = ToolInfo.nToolIndex
@@ -349,7 +350,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
end
-- se OppositeToolDirectionMode è Optimized, se possibile e necessario, si attiva la lavorazione dal lato opposto per garantire taglio concorde e verso l'alto (massima qualità)
if ( OppositeToolDirectionMode == 'Optimized') and ( Proc.nFct == 1) and ( FaceData.IsFaceRhomboid( FaceToMachine)) then
if ( OppositeToolDirectionMode == 'Optimized') and ( Proc.nFct == 1) and ( FaceData.IsFaceParallelogram( FaceToMachine)) then
OppositeToolDirectionMode = 'Disabled'
@@ -359,7 +360,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
-- si attiva OppositeToolDirection solo se il taglio è fattibile anche in direzione opposta
local EdgeToMachineOpposite = BeamLib.FindEdgeBestOrientedAsDirection( FaceToMachine.Edges, -Cutting.vtToolDirection)
local bIsApplicableOpposite, sBladeEngagementOpposite, dDownUpElevationOpposite = MachiningLib.GetBladeEngagement( FaceToMachine, EdgeToMachineOpposite, Part.b3Raw, TOOLS[nToolIndex])
local bIsApplicableOpposite, sBladeEngagementOpposite, dDownUpElevationOpposite = MachiningLib.GetBladeEngagement( FaceToMachine, EdgeToMachineOpposite, Part.b3Raw, TOOLS[nToolIndex], bAllowEntryFromInternalEdge)
if bIsApplicableOpposite and ( sBladeEngagementOpposite == Cutting.sBladeEngagement) then
@@ -421,7 +422,7 @@ function FACEBYBLADE.Make( Proc, Part, FaceToMachine, EdgeToMachine, OptionalPar
Cutting.sEdgeUsage = 'Standard'
if bReduceBladePath
and ( Proc.nFct == 1)
and FaceData.IsFaceRectangular( FaceToMachine) then
and FaceData.IsFaceRectangle( FaceToMachine) then
local bIsTopBlade = TOOLS[nToolIndex].SetupInfo.HeadType.bTop
Cutting.dMaxRadialOffset = TOOLS[nToolIndex].dMaxMaterial - Cutting.dDepthToMachine - BeamData.CUT_SIC