re-enable old school support generation. fix undefined error resulting from unset shadow
This commit is contained in:
parent
901172c7f3
commit
97e1006172
4 changed files with 7 additions and 5 deletions
|
|
@ -199,8 +199,8 @@
|
|||
|
||||
// fixed supports (generated ahead of time)
|
||||
const fixed = Object.values(settings.widget[widget.id].support || {});
|
||||
let shadow;
|
||||
if (fixed.length) {
|
||||
let shadow = null;
|
||||
if (fixed.length || spro.sliceSupportEnable) {
|
||||
// create shadow. TODO test if any supports set
|
||||
let alltops = slices.map(slice => slice.topPolys()).flat();
|
||||
shadow = POLY.union(alltops,null,0.1);
|
||||
|
|
@ -946,7 +946,7 @@
|
|||
});
|
||||
|
||||
// merge pillars and replace with convex hull of outer points (aka smoothing)
|
||||
pillars = POLY.union(pillars).forEach(function(pillar) {
|
||||
pillars = POLY.union(pillars, null, true).forEach(function(pillar) {
|
||||
supports.push(BASE.newPolygon().createConvexHull(pillar.points));
|
||||
});
|
||||
})();
|
||||
|
|
|
|||
Loading…
Reference in a new issue