fix thin wall (centers) for compound polys

This commit is contained in:
Stewart Allen 2021-02-21 00:17:21 -05:00
commit d5c6e8aad6
2 changed files with 33 additions and 21 deletions

View file

@ -584,12 +584,12 @@
top.shells = layers.map(r => r.mid).flat();
top.gaps = layers.map(r => r.gap).flat();
let off = offsetN;
let min = off * 0.9;
let min = off * 0.75;
let max = off * 4;
for (let poly of layers.map(r => r.gap).flat()) {
let centers = poly.centers(off/2, z, min, max, {lines:false});
top.fill_sparse.appendAll(centers);
// top.thin_fill.appendAll(centers);
// top.fill_lines.appendAll(centers);
}
} else if (opt.thin) {
top.thin_fill = [];