Compare commits
23 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 25779abb81 | |||
| 1a4baaf1be | |||
| 20fccb24af | |||
| aa94102b28 | |||
| a2d89cd98d | |||
| 6e2e976675 | |||
| db5ae17d63 | |||
| 3e9da2724b | |||
| a1946a4a41 | |||
| 87cb7480be | |||
| 9563735770 | |||
| d1218915f7 | |||
| 19c7a54aa7 | |||
| 7bbed3cb8a | |||
| 25f599a1fa | |||
| c0970c52ff | |||
| 61590f611d | |||
| f8011493f2 | |||
| a76bd31fe4 | |||
| 07a80248dc | |||
| 89838c6f28 | |||
| 764c80824a | |||
| 37da3ba714 |
@@ -20,5 +20,4 @@
|
||||
/bin/LuaLibs/*.lua
|
||||
/bin/Images/*.png
|
||||
.vscode/settings.json
|
||||
bin/LuaLibs/.placeholder
|
||||
bin/Images/.placeholder
|
||||
|
||||
+2
-1
@@ -14,6 +14,7 @@
|
||||
-- 2022/05/02 Consentito allargamento area disponibile per grezzi su tavola da WallData.
|
||||
-- 2023/04/09 Aggiunta gestione flag per taglio feature con outline (da WD.CUT_WITH_OUTLINE).
|
||||
-- 2023/04/17 Aggiunta gestione flag per rotazione grezzo di 180deg (da WD.RAWPART_ROT).
|
||||
-- 2024/02/20 Tolleranza su altezza pannello in grezzo portata a 0.1 mm.
|
||||
|
||||
-- Intestazioni
|
||||
require( 'EgtBase')
|
||||
@@ -348,7 +349,7 @@ if bToProcess then
|
||||
local vWallErr = {}
|
||||
for i = 2, #vWall do
|
||||
local dDimH = vWall[i].Box:getDimZ() + vWall[i].PosY
|
||||
if abs( dDimH - dRawH) > 10 * GEO.EPS_SMALL then
|
||||
if abs( dDimH - dRawH) > 100 * GEO.EPS_SMALL then
|
||||
table.insert( vWallErr, i)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
-- WFeatureTopology.lua by Egaltech s.r.l. 2023/06/23
|
||||
-- Libreria per classificazione topologica feature pareti
|
||||
-- 2023/12/11 Modifiche varie per allineamento con Beam.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local WFeatureTopology = {}
|
||||
@@ -104,11 +105,11 @@ end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
-- restituisce un vettore contenente gli indici delle facce di Proc parallele ad una delle direzioni principali; il check varia in base alla famiglia topologica
|
||||
local function GetFacesParallelToPart( Proc, sFamily)
|
||||
local function GetFacesParallelToPart( Proc, sFamily, bIsThrough)
|
||||
local vFacesParallelToPart = {}
|
||||
for i = 0, Proc.Fct - 1 do
|
||||
local vtN = EgtSurfTmFacetNormVersor( Proc.Id, i, GDB_ID.ROOT)
|
||||
if sFamily == 'Bevel' or sFamily == 'DoubleBevel' then
|
||||
if sFamily == 'Rabbet' or sFamily == 'Bevel' or sFamily == 'DoubleBevel' or sFamily == 'Strip' or sFamily == 'Tunnel' or ( sFamily == 'Groove' and bIsThrough) then
|
||||
local vTriangularFaces = GetTriangularFaces( Proc)
|
||||
local bIsTriangularFace = false
|
||||
-- verifico se la faccia è triangolare
|
||||
@@ -158,7 +159,13 @@ end
|
||||
|
||||
---------------------------------------------------------------------
|
||||
-- riconosce se Proc è una delle topologie standard e, in caso positivo, ne scrive le caratteristiche in campi specifici della Proc stessa restituendo true
|
||||
function WFeatureTopology.Classify( Proc)
|
||||
function WFeatureTopology.Classify( Proc, b3Raw)
|
||||
|
||||
if not Proc.AffectedFaces then Proc.AffectedFaces = WL.GetProcessAffectedFaces( Proc) end
|
||||
if not Proc.Box or Proc.Box:isEmpty() then
|
||||
return false
|
||||
end
|
||||
|
||||
local bRecognized = false
|
||||
local sFamily
|
||||
local bIsThrough
|
||||
@@ -172,23 +179,31 @@ function WFeatureTopology.Classify( Proc)
|
||||
bAllAnglesConcave, bAllRightAngles = AreAllAnglesConcaveOrRight( Proc)
|
||||
local vTriangularFaces = GetTriangularFaces( Proc)
|
||||
local bIsAnyDimensionLongAsPart = IsAnyDimensionLongAsPart( Proc)
|
||||
local vFacesWithOneAdj = WFeatureTopology.GetFacesWithGivenAdjacencyNumber( Proc, 1)
|
||||
local vFacesWithTwoAdj = WFeatureTopology.GetFacesWithGivenAdjacencyNumber( Proc, 2)
|
||||
local vFacesWithThreeAdj = WFeatureTopology.GetFacesWithGivenAdjacencyNumber( Proc, 3)
|
||||
local vFacesWithFourAdj = WFeatureTopology.GetFacesWithGivenAdjacencyNumber( Proc, 4)
|
||||
local dRawW, dRawH, dRawL = b3Raw:getDimY(), b3Raw:getDimZ(), b3Raw:getDimX()
|
||||
local bIsFeatureCuttingEntireSection = WL.IsFeatureCuttingEntireSection( Proc.Box, dRawW, dRawH, dRawL)
|
||||
|
||||
if Proc.IsOutline then
|
||||
sFamily = 'OUTLINE'
|
||||
elseif Proc.Prc == 40 then
|
||||
sFamily = 'DRILLING'
|
||||
elseif Proc.Fct == 1 and bIsAnyDimensionLongAsPart and bIsFeatureCuttingEntireSection then
|
||||
sFamily = 'Cut'
|
||||
elseif Proc.Fct == 1 and bIsAnyDimensionLongAsPart then
|
||||
sFamily = 'Bevel'
|
||||
bIsThrough = true
|
||||
elseif Proc.Fct == 2 and bAllAnglesConcave and #vTriangularFaces == 1 then
|
||||
sFamily = 'Bevel'
|
||||
bIsThrough = false
|
||||
elseif Proc.Fct == 2 and bAllAnglesConcave then
|
||||
elseif Proc.Fct == 2 and bAllAnglesConcave and ( Proc.AffectedFaces.Left or Proc.AffectedFaces.Right) and ( Proc.AffectedFaces.Front or Proc.AffectedFaces.Back) then
|
||||
sFamily = 'Rabbet'
|
||||
bIsThrough = true
|
||||
elseif Proc.Fct == 2 and bAllAnglesConcave then
|
||||
sFamily = 'Groove'
|
||||
bIsThrough = true
|
||||
elseif Proc.Fct == 2 and not bAllAnglesConcave and bIsAnyDimensionLongAsPart then
|
||||
sFamily = 'DoubleBevel'
|
||||
bIsThrough = true
|
||||
@@ -207,11 +222,14 @@ function WFeatureTopology.Classify( Proc)
|
||||
elseif Proc.Fct == 4 and bAllAnglesConcave and #vFacesWithTwoAdj == 4 and bIsAnyDimensionLongAsPart then
|
||||
sFamily = 'Tunnel'
|
||||
bIsThrough = true
|
||||
elseif Proc.Fct >= 4 and #vFacesWithOneAdj == 2 and bIsAnyDimensionLongAsPart then
|
||||
sFamily = 'Strip'
|
||||
bIsThrough = true
|
||||
elseif Proc.Fct == 5 and bAllAnglesConcave and #vFacesWithFourAdj == 1 then
|
||||
sFamily = 'Pocket'
|
||||
bIsThrough = false
|
||||
end
|
||||
local vFacesParallelToPart = GetFacesParallelToPart( Proc, sFamily)
|
||||
local vFacesParallelToPart = GetFacesParallelToPart( Proc, sFamily, bIsThrough)
|
||||
bIsParallel = ( #vFacesParallelToPart == Proc.Fct)
|
||||
|
||||
if sFamily == 'OUTLINE' or sFamily == 'DRILLING' then
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
-- 2023/10/02 Correzione a MakeCustomPath per calcolare correttamente puliture spigoli di tipo 2 (Clean 30) e 3 (Gola di Scarico).
|
||||
-- 2023/11/14 Spostamento di alcune funzioni in WallLib.
|
||||
-- Aggiunta dei FreeContour in doppio.
|
||||
-- 2023/12/13 In MakeByPocket aggiunta la possibilità di svuotare tasche passanti.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local WPF = {}
|
||||
@@ -2100,7 +2101,7 @@ local function MakeByMill( Proc, nRawId, b3Raw)
|
||||
EgtSetMachiningParam( MCH_MP.WORKSIDE, MCH_MILL_WS.RIGHT)
|
||||
end
|
||||
|
||||
-- se lamatura affondata speciale, setto attacco e stacco al centro
|
||||
-- se lamatura affondata speciale (cliente 90480029), setto attacco e stacco al centro
|
||||
local bIsRecessedCounterBore = ( Proc.Box:getMax():getZ() < b3Raw:getMax():getZ() + 10 * GEO.EPS_SMALL) and
|
||||
( nTool_ID == WD.RECESSED_COUNTERBORE_TOOLID or 0) and
|
||||
( EgtCurveIsACircle( AuxId))
|
||||
@@ -2120,12 +2121,16 @@ local function MakeByMill( Proc, nRawId, b3Raw)
|
||||
EgtSetMachiningParam( MCH_MP.LOELEV, 0)
|
||||
-- imposto step
|
||||
local dMaxMat = EgtTdbGetCurrToolParam( MCH_TP.MAXMAT) or 0
|
||||
local dStep = EgtGetMachiningParam( MCH_MP.STEP)
|
||||
if dStep < GEO.EPS_SMALL then dStep = 0.75 * dMaxMat end
|
||||
local nStep = ceil( ( dDepth - dMaxMat) / dStep)
|
||||
dStep = max( ( dDepth - dMaxMat) / max( nStep, 1), 0)
|
||||
local dMaxElev = max( ( nStep + 1) * dStep - GEO.EPS_SMALL, 0)
|
||||
EgtSetMachiningParam( MCH_MP.STEP, dStep)
|
||||
--
|
||||
-- su richiesta del cliente 90480029 si usa sempre step unico a prescindere dalla geometria
|
||||
--
|
||||
-- local dStep = EgtGetMachiningParam( MCH_MP.STEP)
|
||||
-- if dStep < GEO.EPS_SMALL then dStep = 0.75 * dMaxMat end
|
||||
-- local nStep = ceil( ( dDepth - dMaxMat) / dStep)
|
||||
-- dStep = max( ( dDepth - dMaxMat) / max( nStep, 1), 0)
|
||||
-- local dMaxElev = max( ( nStep + 1) * dStep - GEO.EPS_SMALL, 0)
|
||||
EgtSetMachiningParam( MCH_MP.STEP, dMaxMat)
|
||||
local dMaxElev = dMaxMat
|
||||
-- imposto elevazione e forzo attacco dal lato aperto
|
||||
EgtSetMachiningParam( MCH_MP.USERNOTES, 'MaxElev=' .. EgtNumToString( dMaxElev, 1) .. ';OutRaw=3;')
|
||||
end
|
||||
@@ -2350,6 +2355,7 @@ end
|
||||
---------------------------------------------------------------------
|
||||
local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
-- recupero e verifico l'entità curva
|
||||
local nAddGrpId = WL.GetAddGroup( Proc.PartId)
|
||||
local bOpposite = false
|
||||
local AuxId = EgtGetInfo( Proc.Id, 'AUXID', 'i') or 0
|
||||
local vtExtr
|
||||
@@ -2382,11 +2388,48 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
break
|
||||
end
|
||||
end
|
||||
-- se tasca verticale si permette la svuotatura anche se passante, lavorando la faccia di fondo aggiunta
|
||||
local nProcTmWithAddedBottomSurfaceId
|
||||
if not nFacet and not bPocketBotface and Proc.AffectedFaces.Top and Proc.AffectedFaces.Bottom and AreSameOrOppositeVectorApprox( vtExtr, Z_AX()) then
|
||||
local nFirstLoopId, nLoopsCount = EgtExtractSurfTmLoops( Proc.Id, nAddGrpId)
|
||||
local dMinZ = GEO.INFINITO
|
||||
local nBottomLoopId = GDB_ID.NULL
|
||||
for i = 1, nLoopsCount do
|
||||
local nCurrentLoopId = nFirstLoopId + i - 1
|
||||
local b3Loop = EgtGetBBoxGlob( nCurrentLoopId, GDB_BB.STANDARD)
|
||||
local dCurrentZ = b3Loop:getMin():getZ()
|
||||
if dCurrentZ < dMinZ then
|
||||
dMinZ = dCurrentZ
|
||||
nBottomLoopId = nCurrentLoopId
|
||||
end
|
||||
end
|
||||
local nAddedBottomSurface = EgtSurfTmByFlatContour( nAddGrpId, nBottomLoopId)
|
||||
local vtNAddedBottomSurface = EgtSurfTmFacetNormVersor( nAddedBottomSurface, 0)
|
||||
if AreOppositeVectorApprox( vtNAddedBottomSurface, Z_AX()) then EgtInvertSurf( nAddedBottomSurface) end
|
||||
nProcTmWithAddedBottomSurfaceId = EgtSurfTmBySewing( nAddGrpId, { nAddedBottomSurface, Proc.Id}, false)
|
||||
if nProcTmWithAddedBottomSurfaceId then
|
||||
-- ricerco la faccia di fondo della trimesh (gli id potrebbero essere cambiati)
|
||||
for i = 1, Proc.Fct do
|
||||
local vtN = EgtSurfTmFacetNormVersor( nProcTmWithAddedBottomSurfaceId, i-1, GDB_ID.ROOT)
|
||||
if abs( vtN * vtExtr) > 0.99 then
|
||||
nFacet = i - 1
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
-- elimino le geometrie che non servono più
|
||||
for i = 1, nLoopsCount do
|
||||
EgtErase( nFirstLoopId + i - 1)
|
||||
end
|
||||
EgtErase( nAddedBottomSurface)
|
||||
end
|
||||
if not nFacet then
|
||||
return MakeByMill( Proc, nRawId, b3Raw)
|
||||
end
|
||||
-- se ho creato la faccia di fondo utilizzo quella
|
||||
local nSurfId = nProcTmWithAddedBottomSurfaceId or Proc.Id
|
||||
-- se la faccia di fondo ha confini aperti, devo lavorarla direttamente
|
||||
local vAdj = EgtSurfTmFacetAdjacencies( Proc.Id, nFacet)[1] or {}
|
||||
local vAdj = EgtSurfTmFacetAdjacencies( nSurfId, nFacet)[1] or {}
|
||||
for i = 1, #vAdj do
|
||||
if vAdj[i] == - 1 then
|
||||
bPocketBotface = true
|
||||
@@ -2397,11 +2440,10 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
local dDepth = EgtIf( bPocketBotface, 0, abs( EgtCurveThickness( AuxId)))
|
||||
local dOriDepth = dDepth
|
||||
-- dati della faccia di fondo
|
||||
local _, dH, dV = EgtSurfTmFacetMinAreaRectangle( Proc.Id, nFacet, GDB_ID.ROOT)
|
||||
local _, dH, dV = EgtSurfTmFacetMinAreaRectangle( nSurfId, nFacet, GDB_ID.ROOT)
|
||||
local dDiam = min( dH, dV)
|
||||
local dElev = WL.GetFaceElevation( Proc.Id, nFacet, nRawId)
|
||||
local dElev = WL.GetFaceElevation( nSurfId, nFacet, nRawId)
|
||||
-- gruppo ausiliario
|
||||
local nAddGrpId = WL.GetAddGroup( Proc.PartId)
|
||||
local nNewProc, nNumFacet = RemoveBottomFaceAndReorder( Proc, nAddGrpId, nFacet)
|
||||
-- se ho forma a L
|
||||
local bIsL = ( nNumFacet == 2 or WL.TestElleShape3( nNewProc, nNumFacet) or WL.TestElleShape4( nNewProc, nNumFacet) == 2)
|
||||
@@ -2440,7 +2482,7 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
end
|
||||
end
|
||||
-- inserisco la lavorazione di svuotatura
|
||||
local sName = 'Pock_' .. ( EgtGetName( Proc.Id) or tostring( Proc.Id))
|
||||
local sName = 'Pock_' .. ( EgtGetName( nSurfId) or tostring( nSurfId))
|
||||
local nMchFId = WM.AddMachining( Proc, sName, sPocketing)
|
||||
if not nMchFId then
|
||||
local sErr = 'Error adding machining ' .. sName .. '-' .. sPocketing
|
||||
@@ -2450,7 +2492,7 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
EgtSetInfo( nMchFId, 'Part', Proc.PartId)
|
||||
-- aggiungo geometria
|
||||
if bPocketBotface then
|
||||
EgtSetMachiningGeometry( {{ Proc.Id, nFacet}})
|
||||
EgtSetMachiningGeometry( {{ nSurfId, nFacet}})
|
||||
else
|
||||
EgtSetMachiningGeometry( {{ AuxId, -1}})
|
||||
end
|
||||
@@ -2483,7 +2525,7 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
local bAppOk = EgtApplyMachining( true, false)
|
||||
if not bAppOk and not bPocketBotface then
|
||||
bPocketBotface = true
|
||||
EgtSetMachiningGeometry( {{ Proc.Id, nFacet}})
|
||||
EgtSetMachiningGeometry( {{ nSurfId, nFacet}})
|
||||
dDepth = 0
|
||||
local dThElev = dThDiam / 2 * sqrt( vtExtr:getX() * vtExtr:getX() + vtExtr:getY() * vtExtr:getY())
|
||||
if dElev + dThElev > dMaxDepth + 10 * GEO.EPS_SMALL then
|
||||
@@ -2515,7 +2557,7 @@ local function MakeByPocket( Proc, nRawId, b3Raw)
|
||||
else
|
||||
EgtErase( nNewProc)
|
||||
if nConeCut == 1 then
|
||||
local sErr = 'Clean corner 60° not applid because thickness: ' .. EgtNumToString( dThick, 2) ..
|
||||
local sErr = 'Clean corner 60° not applied because thickness: ' .. EgtNumToString( dThick, 2) ..
|
||||
' is bigger than parameter MAX_CLEAN_CRN60: ' .. EgtNumToString( WD.MAX_CLEAN_CRN60 , 2)
|
||||
EgtOutLog( sErr)
|
||||
elseif nConeCut == 2 then
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
-- 2023/11/14 Aggiunta tasche in doppio.
|
||||
-- Miglioramenti sostanziali nella gestione delle tasche.
|
||||
-- 2023/11/16 Fresature a salire estese a groove cieche.
|
||||
-- 2024/02/20 Piccola correzione ai casi in cui si utilizza il SIDESTEP.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local WPL = {}
|
||||
@@ -1980,7 +1981,7 @@ local function MakeSideGrooveByMill( Proc, nFacet, nRawId, b3Raw, sCustomMach, d
|
||||
local dStepOri
|
||||
if not bExcludeSideMill then
|
||||
local nSideStep = 1
|
||||
if dSideStep > 0 and not ( bEnablePreMill or bAsEnablePreMill) and nModifyLeadInOut < 1 then
|
||||
if dSideStep > 0 and not ( bEnablePreMill or bAsEnablePreMill) then
|
||||
nSideStep = ceil( dElev / dSideStep)
|
||||
dSideStep = max( dElev / nSideStep, 0)
|
||||
end
|
||||
|
||||
+27
-14
@@ -1,4 +1,4 @@
|
||||
-- WallExec.lua by Egaltech s.r.l. 2023/10/16
|
||||
-- WallExec.lua by Egaltech s.r.l. 2024/02/20
|
||||
-- Libreria esecuzione lavorazioni per Pareti
|
||||
-- 2023/05/25 Aggiunto ordinamento in base a priorità da btl.
|
||||
-- 2023/06/07 Nel caso di outline con priorità aggiunta la rimozione degli sfridi nella lavorazione successiva.
|
||||
@@ -7,6 +7,8 @@
|
||||
-- 2023/10/16 Aggiunta gestione Aree vietate (LockOut) per chiodature.
|
||||
-- 2023/11/14 Modifiche sostanziali per l'aggiunta delle lavorazioni in doppio.
|
||||
-- In Collect aggiunto il recupero preliminare di varie informazioni sulla feature.
|
||||
-- 2023/12/11 In ClassifyTopology si passa ora anche l'Id del grezzo (allineamento Topology con Beam).
|
||||
-- 2024/02/20 Aggiunta gestione DeltaX/Y/Z del pannello dall'origine da BTL.
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local WallExec = {}
|
||||
@@ -79,33 +81,43 @@ function WallExec.ProcessWalls( dRawL, dRawW, dRawH, vWall, bMachGroupOk, bNewPr
|
||||
local OrigOnTab
|
||||
local nCorner
|
||||
local sOrigCorner = WD.ORIG_CORNER or 'BR'
|
||||
local BtlInfoId = EgtGetFirstNameInGroup( GDB_ID.ROOT, 'BtlInfo') or GDB_ID.NULL
|
||||
if WD.GetOrigCorner then
|
||||
sOrigCorner = WD.GetOrigCorner( EgtGetInfo( EgtGetFirstNameInGroup( GDB_ID.ROOT, 'BtlInfo') or GDB_ID.NULL, 'REFPOS', 'i') or 0)
|
||||
end
|
||||
sOrigCorner = WD.GetOrigCorner( EgtGetInfo( BtlInfoId, 'REFPOS', 'i') or 0)
|
||||
end
|
||||
-- offset da interfaccia
|
||||
local dDeltaXFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAY', 'd') or 0
|
||||
local dDeltaYFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAX', 'd') or 0
|
||||
local dDeltaZFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAZ', 'd') or 0
|
||||
-- se da interfaccia arriva un valore > 0 si usa quello, altrimenti si legge da WallData (default 0)
|
||||
local DeltaX = EgtIf( dDeltaXFromBtl > 0, dDeltaXFromBtl, WD.DELTA_X or 0)
|
||||
local DeltaY = EgtIf( dDeltaYFromBtl > 0, dDeltaYFromBtl, WD.DELTA_Y or 0)
|
||||
local DeltaZ = EgtIf( dDeltaZFromBtl > 0, dDeltaZFromBtl, WD.DELTA_Z or 0)
|
||||
|
||||
if sOrigCorner == 'TL' then
|
||||
nCorner = MCH_CR.TL
|
||||
OrigOnTab = Point3d( 0 + abs( WD.DELTA_X or 0), b3Tab:getDimY() - abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( 0 + abs( DeltaX), b3Tab:getDimY() - abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'BL' then
|
||||
nCorner = MCH_CR.BL
|
||||
OrigOnTab = Point3d( 0 + abs( WD.DELTA_X or 0), abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( 0 + abs( DeltaX), abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'TR' then
|
||||
nCorner = MCH_CR.TR
|
||||
OrigOnTab = Point3d( b3Tab:getDimX() - abs( WD.DELTA_X or 0), b3Tab:getDimY() - abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( b3Tab:getDimX() - abs( DeltaX), b3Tab:getDimY() - abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'BR' then
|
||||
nCorner = MCH_CR.BR
|
||||
OrigOnTab = Point3d( b3Tab:getDimX() - abs( WD.DELTA_X or 0), abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( b3Tab:getDimX() - abs( DeltaX), abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'TM' then
|
||||
nCorner = MCH_CR.TR
|
||||
OrigOnTab = Point3d( WD.MID_REF - abs( WD.DELTA_X or 0), b3Tab:getDimY() - abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( WD.MID_REF - abs( DeltaX), b3Tab:getDimY() - abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'BM' then
|
||||
nCorner = MCH_CR.BR
|
||||
OrigOnTab = Point3d( WD.MID_REF - abs( WD.DELTA_X or 0), abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( WD.MID_REF - abs( DeltaX), abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'TN' then
|
||||
nCorner = MCH_CR.TL
|
||||
OrigOnTab = Point3d( WD.NEW_REF + abs( WD.DELTA_X or 0), b3Tab:getDimY() - abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( WD.NEW_REF + abs( DeltaX), b3Tab:getDimY() - abs( DeltaY), DeltaZ)
|
||||
elseif sOrigCorner == 'BN' then
|
||||
nCorner = MCH_CR.BL
|
||||
OrigOnTab = Point3d( WD.NEW_REF + abs( WD.DELTA_X or 0), abs( WD.DELTA_Y or 0), ( WD.DELTA_Z or 0))
|
||||
OrigOnTab = Point3d( WD.NEW_REF + abs( DeltaX), abs( DeltaY), DeltaZ)
|
||||
end
|
||||
-- Impostazione dell'attrezzaggio di default
|
||||
EgtImportSetup()
|
||||
@@ -309,11 +321,12 @@ local function ClassifyFeatures( vProc, b3Raw)
|
||||
end
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
local function ClassifyTopology( vProc)
|
||||
local function ClassifyTopology( vProc, nRawId)
|
||||
local b3Raw = EgtGetRawPartBBox( nRawId)
|
||||
local nRecognized = 0
|
||||
for i = 1, #vProc do
|
||||
local Proc = vProc[i]
|
||||
if Topology.Classify( Proc) then
|
||||
if Topology.Classify( Proc, b3Raw) then
|
||||
nRecognized = nRecognized + 1
|
||||
end
|
||||
end
|
||||
@@ -1085,7 +1098,7 @@ function WallExec.ProcessFeatures()
|
||||
vProc = EgtJoinTables( vProc, vPartProc)
|
||||
end
|
||||
-- classifico topologicamente le feature
|
||||
ClassifyTopology( vProc)
|
||||
ClassifyTopology( vProc, nRawId)
|
||||
-- classifico le feature
|
||||
ClassifyFeatures( vProc, b3Raw)
|
||||
-- recupero l'elenco delle aree vietate alle chiodature
|
||||
|
||||
+9
-1
@@ -2,6 +2,7 @@
|
||||
-- Libreria globale per Pareti
|
||||
-- 2023/06/26 Spostata qui Is3EdgesApprox da FreeContour. Ora cerca autonomamente il gruppo se non viene passato.
|
||||
-- 2023/11/14 Aggiunte funzioni GetProcessAffectedFaces, GetProcessDistanceToNearestParts, GetProcessDistanceToRawPart.
|
||||
-- 2023/12/11 Aggiunta funzione IsFeatureCuttingEntireSection (allineamento Topology con Beam).
|
||||
|
||||
-- Tabella per definizione modulo
|
||||
local WallLib = {}
|
||||
@@ -534,7 +535,7 @@ function WallLib.GetNailLockOutAreas( vProc)
|
||||
if AuxId then AuxId = AuxId + vProc[i].Id end
|
||||
if AuxId then
|
||||
local nAddGrpId = WallLib.GetAddGroup( vProc[i].PartId)
|
||||
local nSfrId = EgtSurfFlatRegion( nAddGrpId, {AuxId})
|
||||
local nSfrId = EgtSurfFlatRegion( nAddGrpId, {AuxId})
|
||||
if nSfrId then
|
||||
table.insert( vNLO, nSfrId)
|
||||
end
|
||||
@@ -544,5 +545,12 @@ function WallLib.GetNailLockOutAreas( vProc)
|
||||
return vNLO
|
||||
end
|
||||
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
-- restituisce vero se la feature con box b3Proc taglia l'intera sezione della parete, rappresentata dalle sue dimensioni W, H e L
|
||||
function WallLib.IsFeatureCuttingEntireSection( b3Proc, dRawW, dRawH, dRawL)
|
||||
return ( ( ( abs( b3Proc:getDimY() - dRawW) < 10 * GEO.EPS_SMALL or b3Proc:getDimY() > dRawW) or ( abs( b3Proc:getDimX() - dRawL) < 10 * GEO.EPS_SMALL or b3Proc:getDimX() > dRawL)) and (abs(b3Proc:getDimZ() - dRawH) < 10 * GEO.EPS_SMALL or b3Proc:getDimZ() > dRawH))
|
||||
end
|
||||
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
return WallLib
|
||||
|
||||
@@ -1,5 +1,20 @@
|
||||
==== Wall Update Log ====
|
||||
|
||||
Versione 2.6b2 (21/02/2024)
|
||||
- Added : aggiunta gestione spostamento pannello rispetto a origine da dato BTL di TS3v7.
|
||||
|
||||
Versione 2.6b1 (20/02/2024)
|
||||
- Modif : In BatchProcess tolleranza su altezza pannello in grezzo portata a 0.1 mm
|
||||
- Fixed : in LapJoint piccola correzione ai casi in cui si utilizza il SIDESTEP.
|
||||
|
||||
Versione 2.5l2 (21/12/2023)
|
||||
- Fixed : in FreeContour -> MakeByPocket corretto un bug che provocava la cancellazione della feature dopo averla lavorata
|
||||
|
||||
Versione 2.5l1 (13/12/2023)
|
||||
- Modif : modifiche a WallExec, WallLib, FeatureTopology per allineamento Topology con Beam
|
||||
- Modif : in FreeContour -> MakeByPocket aggiunta la possibilità di svuotare tasche passanti
|
||||
- Modif : in FreeContour -> MakeByPocket in tasche speciali cliente 90480029 forzato step unico
|
||||
|
||||
Versione 2.5k1 (14/11/2023)
|
||||
- Added : aggiunte lavorazioni in doppio.
|
||||
- Modif : miglioramenti vari alla lavorazione tasche, in particolare in presenza di pezzi vicini.
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
-- Version.lua by Egalware s.r.l. 2023/10/11
|
||||
-- Version.lua by Egalware s.r.l. 2024/02/20
|
||||
-- Gestione della versione di Wall
|
||||
|
||||
NAME = 'Wall'
|
||||
VERSION = '2.5k1'
|
||||
VERSION = '2.6b2'
|
||||
MIN_EXE = '2.5b3'
|
||||
|
||||
Reference in New Issue
Block a user