- in BLADETOWASTE se i cubetti falliscono si riprovano con la SAFE_DIM_DICE, se disponibile
- in PreSimulationLib per i test collisione con il grezzo si usa la vera dimensione della barra restante
This commit is contained in:
@@ -70,7 +70,7 @@ local function GetRestlengthSurfTm( Part)
|
||||
|
||||
-- si costruisce il box in globale
|
||||
local ptRestLengthMax = Point3d( Part.b3Part:getMin()) + X_AX() * 500 * GEO.EPS_SMALL
|
||||
local ptRestLengthMin = Point3d( Part.b3Part:getMin():getX() - 2000, Part.b3Part:getMax():getY(), Part.b3Part:getMax():getZ())
|
||||
local ptRestLengthMin = Point3d( Part.b3Part:getMin():getX() - Part.dRestLength, Part.b3Part:getMax():getY(), Part.b3Part:getMax():getZ())
|
||||
local b3RestLength = BBox3d( ptRestLengthMin, ptRestLengthMax)
|
||||
-- si crea la trimesh dal box
|
||||
local idRestLengthBoxTm = EgtSurfTmBBox( Part.idTempGroup, b3RestLength , false, GDB_RT.GLOB)
|
||||
|
||||
@@ -951,6 +951,23 @@ local function CutWithDicing( Proc, Part, OptionalParameters)
|
||||
|
||||
bIsDicingOk, Machinings, bMoveAfterSplit = CalculateDiceMachinings( vCuts, Parameters)
|
||||
|
||||
-- se i cubetti falliscono si riprova con la dimensione ridotta (ad esempio quando tocca l'asse Z nei cubetti in coda)
|
||||
if not bIsDicingOk and BeamData.SAFE_DIM_DICE then
|
||||
dDiceDimension = BeamData.SAFE_DIM_DICE - BeamData.CUT_EXTRA
|
||||
OptionalParametersDiceCut.dOffsetParallel = dDiceDimension
|
||||
OptionalParametersDiceCut.dOffsetOrthogonal = dDiceDimension
|
||||
vCuts = DiceCut.GetDice( Part, Face1, Face2, OptionalParametersDiceCut)
|
||||
|
||||
-- se nessun cubetto trovato, si richiama ricorsivamente la BladeToWaste forzando di non fare i cubetti
|
||||
if #vCuts == 0 then
|
||||
OptionalParameters.bDisableDicing = true
|
||||
Machinings, Result = BLADETOWASTE.Make( Proc, Part, OptionalParameters)
|
||||
return Machinings, Result
|
||||
end
|
||||
|
||||
bIsDicingOk, Machinings, bMoveAfterSplit = CalculateDiceMachinings( vCuts, Parameters)
|
||||
end
|
||||
|
||||
if not bIsDicingOk then
|
||||
Result = FeatureLib.GetStrategyResultNotApplicable()
|
||||
return {}, Result
|
||||
|
||||
Reference in New Issue
Block a user