LapJoint - Aggiunto caso di Slot su testa o coda con lato di fondo inclinato e lati aperti sui fianchi.

This commit is contained in:
daniele.nicoli
2026-04-17 12:54:35 +02:00
parent 895740feff
commit a5cd84172e
2 changed files with 24 additions and 6 deletions
+1 -1
View File
@@ -588,7 +588,7 @@ function BeamLib.GetFaceWithMostAdj( Proc, nPartId, bCompare3Fc, dCosSideAng)
end
local bEveryFaceHasUndercut = ( nFacesWithUnderCut == nFacCnt)
-- tunnel o assimilabile
if Proc.Topology == 'Tunnel' or ( bCompare3Fc and Proc.Topology == 'Groove' and Proc.IsThrough) or ( Proc.Topology == 'Strip' and bEveryFaceHasUndercut) then
if Proc.Topology == 'Tunnel' or ( bCompare3Fc and Proc.Topology == 'Groove' and Proc.IsThrough and not (Proc.AffectedFaces.Left or Proc.AffectedFaces.Right)) or ( Proc.Topology == 'Strip' and bEveryFaceHasUndercut) then
if Proc.IsParallel or Proc.AllRightAngles then
return -1, GEO.INFINITO, true
else
+23 -5
View File
@@ -3473,17 +3473,35 @@ local function MakeByChainOrSaw( Proc, nPhase, nRawId, nPartId, nFacInd,
-- imposto offset radiale
local dOffs = ( i - 1) * dStep
EgtSetMachiningParam( MCH_MP.OFFSR, dOffs)
local bElevAdj
local dToolEntryAngle, _, _, dTanToolEntryAngle = GetToolEntryAngle( Proc, rfFac:getVersZ())
-- se necessario, avverto limitazione dell'affondamento
if dElev > dMaxDepth + 10 * GEO.EPS_SMALL then
EgtSetMachiningParam( MCH_MP.DEPTH, dMaxDepth)
sWarn = 'Warning in LapJoint : elevation (' .. EgtNumToString( dElev, 1) .. ') bigger than max tool depth (' .. EgtNumToString( dMaxDepth, 1) .. ')'
EgtOutLog( sWarn)
if dElev > dMaxDepth + 10 * GEO.EPS_SMALL then
if Proc.Fct == 3 and Proc.Topology == 'Groove' and Proc.IsThrough and (Proc.AffectedFaces.Left or Proc.AffectedFaces.Right) then
local Edges = BL.GetEdgesInfo( Proc, Proc.Face[nFacAdj+1])
local dWorkEdgeWidth
for i = 1, #Edges do
if Edges[i].AdjacentFaceId == nFacInd then
dWorkEdgeWidth = Edges[i].Length
break
end
end
local dDeltaDepth = dWorkEdgeWidth * cos( dToolEntryAngle)
bElevAdj = true
EgtSetMachiningParam( MCH_MP.DEPTH, dMaxDepth - dDeltaDepth)
else
EgtSetMachiningParam( MCH_MP.DEPTH, dMaxDepth)
sWarn = 'Warning in LapJoint : elevation (' .. EgtNumToString( dElev, 1) .. ') bigger than max tool depth (' .. EgtNumToString( dMaxDepth, 1) .. ')'
EgtOutLog( sWarn)
end
--local dDepth = dMaxDepth - dElev
--EgtSetMachiningParam( MCH_MP.DEPTH_STR, 'TH '..EgtNumToString( dDepth, 1))
end
-- imposto massima elevazione
local sUserNotes = EgtGetMachiningParam( MCH_MP.USERNOTES) or ''
sUserNotes = EgtSetValInNotes( sUserNotes, 'MaxElev', EgtNumToString( dElev, 2))
local dElevAdj = EgtIf( bElevAdj, dElev / sin( dToolEntryAngle), dElev)
sUserNotes = EgtSetValInNotes( sUserNotes, 'MaxElev', EgtNumToString( dElevAdj, 2))
EgtSetMachiningParam( MCH_MP.USERNOTES, sUserNotes)
-- eseguo
if not ML.ApplyMachining( true, false) then