Feature/MortiseCornerFinishing:

per mortasa implementata la finitura degli angoli con parametro P04=1, con apposito utensile
This commit is contained in:
luca.mazzoleni
2022-07-26 16:46:50 +02:00
parent 8b560421f7
commit 30b30471fc
3 changed files with 84 additions and 18 deletions
+1 -18
View File
@@ -4338,23 +4338,6 @@ local function ManageAntiSplintByMill( Proc, nPhase, nRawId, nPartId, b3Raw,
return true, sMyWarn
end
---------------------------------------------------------------------
-- Trova l'Ind (0 based) della faccia meglio orientata come l'asse vtAx. Restituisce anche vtN e ptC della faccia stessa.
local function FindFaceBestOrientedAsAxis( Proc, vtAx)
local nFaceIndMax = 0
local dMaxComp = 0 ;
for i = 1, Proc.Fct do
local vtN = EgtSurfTmFacetNormVersor( Proc.Id, i - 1, GDB_ID.ROOT)
local dComp = abs( vtN * vtAx)
if dComp > dMaxComp then
nFaceIndMax = i -1
dMaxComp = dComp
end
end
local ptC, vtN = EgtSurfTmFacetCenter( Proc.Id, nFaceIndMax, GDB_ID.ROOT)
return nFaceIndMax, ptC, vtN
end
---------------------------------------------------------------------
local function MakeMoreFaces( Proc, nPhase, nRawId, nPartId, dOvmHead, bSinglePart, bPrevBhSideMill, bAllWithEndCap)
if not BD.MAXDIAM_POCK_CORNER then
@@ -5137,7 +5120,7 @@ local function MakeMoreFaces( Proc, nPhase, nRawId, nPartId, dOvmHead, bSinglePa
local bOrthoFacesMaster = nil
local bSetOpenBorders = nil
-- trovo la faccia con normale più inclinata verso Y
local nFacApproxY, ptCFacApproxY, vtNFacApproxY = FindFaceBestOrientedAsAxis( Proc, Y_AX())
local nFacApproxY, ptCFacApproxY, vtNFacApproxY = BL.FindFaceBestOrientedAsAxis( Proc, Y_AX())
-- se Q03 = 2 e
-- 3 facce a L, oppure
-- 3 facce non a L ma con una faccia favorevole a Y, oppure