filter flats to a minimum of of 1/2 tool area
This commit is contained in:
parent
ab3d06e9ca
commit
5f41d8ec01
1 changed files with 4 additions and 1 deletions
|
|
@ -159,7 +159,10 @@
|
|||
// shift out first (top-most) slice
|
||||
indices.shift();
|
||||
if (op.flats) {
|
||||
let flats = Object.keys(slicer.zFlat)
|
||||
let flatArea = (Math.PI * (toolDiam/2) * (toolDiam/2)) / 2;
|
||||
let flats = Object.entries(slicer.zFlat)
|
||||
.filter(row => row[1] > flatArea)
|
||||
.map(row => row[0])
|
||||
.map(v => parseFloat(v).round(5))
|
||||
.filter(v => v >= zBottom);
|
||||
flats.forEach(v => {
|
||||
|
|
|
|||
Loading…
Reference in a new issue