DataBeam :
- aggiustamenti in GetNearestParalOpposite e GetNearestOrthoOpposite - nel taglio a cubetti si tiene conto se testa da sotto - aggiunta gestione testa da sotto in RidgeLap.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
-- ProcessRidgeLap.lua by Egaltech s.r.l. 2021/06/15
|
||||
-- ProcessRidgeLap.lua by Egaltech s.r.l. 2021/09/10
|
||||
-- Gestione calcolo mezzolegno di testa per Travi
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
@@ -25,6 +25,10 @@ end
|
||||
---------------------------------------------------------------------
|
||||
-- Classificazione della feature
|
||||
function ProcessRidgeLap.Classify( Proc, b3Raw)
|
||||
-- se PF con testa da sotto, ammessa qualunque orientazione
|
||||
if BD.C_SIMM and BD.DOWN_HEAD then
|
||||
return true, false
|
||||
end
|
||||
-- Se più corta del limite si può fare anche da sotto
|
||||
if Proc.Box:getDimX() <= BD.GetMaxLenRidgeLapFromBottom( b3Raw:getDimZ()) then
|
||||
return true, false
|
||||
@@ -89,8 +93,10 @@ function ProcessRidgeLap.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
end
|
||||
-- determino se di testa o di coda
|
||||
local bHead = ( vtN[vFaceOrd[2]]:getX() > 0)
|
||||
-- determino se da lavorare con testa da sotto
|
||||
local bDownHead = ( BD.DOWN_HEAD and vtN[vFaceOrd[3]]:getZ() < -0.1)
|
||||
-- recupero la lavorazione
|
||||
local sCutting = ML.FindCutting( 'HeadSide')
|
||||
local sCutting = ML.FindCutting( 'HeadSide' .. EgtIf( bDownHead, '_H2', ''))
|
||||
if not sCutting then
|
||||
local sErr = 'Error on process ' .. tostring( Proc.Id) .. ' cutting not found in library'
|
||||
EgtOutLog( sErr)
|
||||
@@ -107,6 +113,7 @@ function ProcessRidgeLap.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
end
|
||||
end
|
||||
local dMaxVertDepth = dMaxDepth - ( BD.DECR_VERT_CUT or 0)
|
||||
local dVzLimDwnUp = EgtIf( bDownHead, -2, nil)
|
||||
-- taglio sulla faccia esterna
|
||||
if vFaceOrd[1] ~= 0 then
|
||||
-- recupero gruppo per geometria addizionale
|
||||
@@ -163,7 +170,7 @@ function ProcessRidgeLap.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
end
|
||||
-- lavoro la faccia
|
||||
for j = 1, #vCuts[i] do
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( vCuts[i][j], 0, sCutting, dSawDiam, nOrthoOpposite, nil, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( vCuts[i][j], 0, sCutting, dSawDiam, nOrthoOpposite, dVzLimDwnUp, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
if not bOk then
|
||||
return bOk, sErr
|
||||
end
|
||||
@@ -174,14 +181,14 @@ function ProcessRidgeLap.Make( Proc, nPhase, nRawId, nPartId, dOvmHead)
|
||||
if vFaceOrd[2] ~= 0 then
|
||||
-- inserisco la lavorazione
|
||||
local nOrthoOpposite = BL.GetNearestOrthoOpposite( vtN[vFaceOrd[3]])
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( Proc.Id, vFaceOrd[2] - 1, sCutting, dSawDiam, nOrthoOpposite, nil, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( Proc.Id, vFaceOrd[2] - 1, sCutting, dSawDiam, nOrthoOpposite, dVzLimDwnUp, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
if not bOk then return bOk, sErr end
|
||||
end
|
||||
-- taglio sulla faccia intermedia
|
||||
if vFaceOrd[3] ~= 0 then
|
||||
-- inserisco la lavorazione
|
||||
local nOrthoOpposite = BL.GetNearestOrthoOpposite( EgtIf( bHead, X_AX(), -X_AX()))
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( Proc.Id, vFaceOrd[3] - 1, sCutting, dSawDiam, nOrthoOpposite, nil, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
local bOk, sErr = BL.MakeOneFaceBySaw( Proc.Id, vFaceOrd[3] - 1, sCutting, dSawDiam, nOrthoOpposite, dVzLimDwnUp, 0, BD.CUT_SIC, 0, 0, 0, nil, b3Raw)
|
||||
if not bOk then return bOk, sErr end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user