Modifica nomi variabili secondo nuovo standard
This commit is contained in:
+26
-26
@@ -92,7 +92,7 @@ end
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
function BeamLib.AddPhaseWithRawParts( Part, OriXR, PosXR, dDeltaSucc)
|
||||
EgtAddPhase()
|
||||
local nRawId = Part.IdRaw
|
||||
local nRawId = Part.idRaw
|
||||
local dRawMove = 0
|
||||
while nRawId do
|
||||
EgtKeepRawPart( nRawId)
|
||||
@@ -148,27 +148,27 @@ end
|
||||
-------------------------------------------------------------------------------------------------------------
|
||||
-- restituisce le facce della parte interessate dalla feature Proc
|
||||
function BeamLib.GetAffectedFaces( Proc)
|
||||
local nBoxSolidId = EgtGetFirstNameInGroup( Proc.PartId or GDB_ID.NULL, 'Box')
|
||||
local nBoxSolidId = EgtGetFirstNameInGroup( Proc.idPart or GDB_ID.NULL, 'Box')
|
||||
local b3Part = EgtGetBBoxGlob( nBoxSolidId, GDB_BB.STANDARD)
|
||||
local vtFacesAffected = { Top = false, Bottom = false, Front = false, Back = false, Left = false, Right = false}
|
||||
if Proc.Box and not Proc.Box:isEmpty() then
|
||||
if Proc.Box:getMax():getZ() > b3Part:getMax():getZ() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Top = true
|
||||
local vtFacesAffected = { bTop = false, bBottom = false, bFront = false, bBack = false, bLeft = false, bRight = false}
|
||||
if Proc.b3Box and not Proc.b3Box:isEmpty() then
|
||||
if Proc.b3Box:getMax():getZ() > b3Part:getMax():getZ() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bTop = true
|
||||
end
|
||||
if Proc.Box:getMin():getZ() < b3Part:getMin():getZ() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Bottom = true
|
||||
if Proc.b3Box:getMin():getZ() < b3Part:getMin():getZ() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bBottom = true
|
||||
end
|
||||
if Proc.Box:getMin():getY() < b3Part:getMin():getY() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Front = true
|
||||
if Proc.b3Box:getMin():getY() < b3Part:getMin():getY() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bFront = true
|
||||
end
|
||||
if Proc.Box:getMax():getY() > b3Part:getMax():getY() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Back = true
|
||||
if Proc.b3Box:getMax():getY() > b3Part:getMax():getY() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bBack = true
|
||||
end
|
||||
if Proc.Box:getMin():getX() < b3Part:getMin():getX() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Left = true
|
||||
if Proc.b3Box:getMin():getX() < b3Part:getMin():getX() + 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bLeft = true
|
||||
end
|
||||
if Proc.Box:getMax():getX() > b3Part:getMax():getX() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.Right = true
|
||||
if Proc.b3Box:getMax():getX() > b3Part:getMax():getX() - 500 * GEO.EPS_SMALL then
|
||||
vtFacesAffected.bRight = true
|
||||
end
|
||||
end
|
||||
|
||||
@@ -178,7 +178,7 @@ end
|
||||
---------------------------------------------------------------------
|
||||
-- Funzione per determinare se la faccia ha lati molto corti (trascurabili) ed è quindi approssimabile ad una 3 facce
|
||||
function BeamLib.Is3EdgesApprox( Proc, idFace, nAddGrpId)
|
||||
nAddGrpId = nAddGrpId or BeamLib.GetAddGroup( Proc.PartId)
|
||||
nAddGrpId = nAddGrpId or BeamLib.GetAddGroup( Proc.idPart)
|
||||
if not nAddGrpId then
|
||||
local nEdges = #(EgtSurfTmFacetAdjacencies( Proc.Id, idFace)[1])
|
||||
return ( nEdges == 3)
|
||||
@@ -227,14 +227,14 @@ function BeamLib.GetFaceHvRefDim( nSurfId, idFace, Part)
|
||||
local dDimH = b3HV:getDimX()
|
||||
local dDimV = b3HV:getDimY()
|
||||
-- se definito grezzo (o solido), applico eventuali limiti
|
||||
if Part.RawBox then
|
||||
if Part.b3RawBox then
|
||||
local dCoeffY = abs( frHV:getVersX():getY())
|
||||
if dCoeffY > GEO.EPS_SMALL then
|
||||
dDimH = min( dDimH, Part.RawBox:getDimY() / dCoeffY)
|
||||
dDimH = min( dDimH, Part.b3RawBox:getDimY() / dCoeffY)
|
||||
end
|
||||
local dCoeffZ = abs( frHV:getVersY():getZ())
|
||||
if dCoeffZ > GEO.EPS_SMALL then
|
||||
dDimV = min( dDimV, Part.RawBox:getDimZ() / dCoeffZ)
|
||||
dDimV = min( dDimV, Part.b3RawBox:getDimZ() / dCoeffZ)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -250,8 +250,8 @@ function BeamLib.GetUpdateCustomParameters( CustomStrategyParamList, DefaultStra
|
||||
if CustomStrategyParamList and #CustomStrategyParamList > 0 then
|
||||
for i = 1, #DefaultStrategyParamList do
|
||||
for j = 1, #CustomStrategyParamList do
|
||||
if DefaultStrategyParamList[i].Name == CustomStrategyParamList[j].Name then
|
||||
DefaultStrategyParamList[i].Value = CustomStrategyParamList[j].Value
|
||||
if DefaultStrategyParamList[i].sName == CustomStrategyParamList[j].sName then
|
||||
DefaultStrategyParamList[i].sValue = CustomStrategyParamList[j].sValue
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -265,12 +265,12 @@ function BeamLib.LoadCustomParametersInStrategy( CustomParameters)
|
||||
local Parameters = {}
|
||||
if CustomParameters and #CustomParameters > 0 then
|
||||
for i=1, #CustomParameters do
|
||||
if CustomParameters[i].Type == 'b' then
|
||||
Parameters[CustomParameters[i].Name] = CustomParameters[i].Value == 'true'
|
||||
if CustomParameters[i].sType == 'b' then
|
||||
Parameters[CustomParameters[i].sName] = CustomParameters[i].sValue == 'true'
|
||||
elseif CustomParameters[i].Type == 'd' then
|
||||
Parameters[CustomParameters[i].Name] = tonumber( CustomParameters[i].Value)
|
||||
Parameters[CustomParameters[i].sName] = tonumber( CustomParameters[i].sValue)
|
||||
else -- CustomParameters.Type == 's'
|
||||
Parameters[CustomParameters[i].Name] = CustomParameters[i].Value
|
||||
Parameters[CustomParameters[i].sName] = CustomParameters[i].sValue
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user