From 24e38cdad540c90b3616bdb8282dd6ff2ba92d11 Mon Sep 17 00:00:00 2001 From: "luca.mazzoleni" Date: Wed, 15 Nov 2023 12:26:08 +0100 Subject: [PATCH] in lapjoint modifiche a MakeStaircaseStep --- LuaLibs/ProcessLapJoint.lua | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/LuaLibs/ProcessLapJoint.lua b/LuaLibs/ProcessLapJoint.lua index c24ff45..7d23c74 100644 --- a/LuaLibs/ProcessLapJoint.lua +++ b/LuaLibs/ProcessLapJoint.lua @@ -5692,8 +5692,8 @@ local function MakeStaircaseStep( Proc, nRawId, b3Raw, nPartId) end -- angolo tra le facce local _, _, _, dAng = EgtSurfTmFacetsContact( Proc.Id, 0, 1, GDB_ID.ROOT) - -- l'angolo tra le facce deve essere compreso tra 80 e 90.5 deg - if ( dAng > -89.5 + 10 * GEO.EPS_ANG_SMALL) or ( dAng < -100 - 10 * GEO.EPS_ANG_SMALL) then return false end + -- l'angolo tra le facce deve essere compreso tra 80 e 95 deg + if ( dAng > -85 + 10 * GEO.EPS_ANG_SMALL) or ( dAng < -100 - 10 * GEO.EPS_ANG_SMALL) then return false end -- normali delle facce local vtNRiser = EgtSurfTmFacetNormVersor( Proc.Id, 0, GDB_ID.ROOT) local vtNTread = EgtSurfTmFacetNormVersor( Proc.Id, 1, GDB_ID.ROOT) @@ -5860,15 +5860,9 @@ local function MakeStaircaseStep( Proc, nRawId, b3Raw, nPartId) -- taglio di lama dell'alzata -- calcolo faceuse local nFaceUseRiser = EgtIf( vtNRiser * Z_AX() > -GEO.EPS_SMALL, MCH_MILL_FU.ORTHO_DOWN, MCH_MILL_FU.ORTHO_TOP) - -- divido in passate orizzontali - local nSawStepsRiser = ceil( ( dVRiser - 100 * GEO.EPS_SMALL) / ( dSawMaxDepth * 0.6)) - local dSawStepRiser = 0 - if nSawStepsRiser > 1 then - dSawStepRiser = ( dVRiser - ( dSawMaxDepth * 0.6)) / ( nSawStepsRiser - 1) - end -- lavorazioni della faccia - for i = nSawStepsRiser, 1, -1 do - local dCutRadialOffsetRiser = - dSawStepRiser * ( i - 1) + for i = 2, 1, -1 do + local dCutRadialOffsetRiser = - dVRiser / 2 * ( i - 1) -- componente limite del vettore Z per lama downUp; impostata a -2 per non farla mai rientrare in quel caso local dVzLimDwnUp = -2 local bOkSawRiser, sErr = Fbs.MakeOne( Proc.Id, nFacetRiser, sCutting, dSawDiam, nFaceUseRiser, dVzLimDwnUp, dCutRadialOffsetRiser + dCutExtraSaw, 0, 0, 0, 0, nil, b3Raw)