diff --git a/src/mode/fdm/slice.js b/src/mode/fdm/slice.js index 02ff1b98..df007d4d 100644 --- a/src/mode/fdm/slice.js +++ b/src/mode/fdm/slice.js @@ -695,7 +695,11 @@ * @param {Polygon[]} polys */ function addSolidFills(slice, polys) { - slice.solids.appendAll(polys); + if (slice.solids) { + slice.solids.appendAll(polys); + } else if (polys && polys.length) { + console.log({no_solids_in: slice, for: polys}) + } }; /** diff --git a/src/mode/sla/export.js b/src/mode/sla/export.js index a1461877..fd41292d 100644 --- a/src/mode/sla/export.js +++ b/src/mode/sla/export.js @@ -266,7 +266,7 @@ layerBytes = width * height, coded; - if (legacy) { + if (SLA.legacy) { let converted = conf.lines.map((line, index) => { let count = line.length / 4; let bits = new Uint8Array(line.length / 4); diff --git a/src/mode/sla/slice.js b/src/mode/sla/slice.js index 9341a674..cfbc5462 100644 --- a/src/mode/sla/slice.js +++ b/src/mode/sla/slice.js @@ -584,7 +584,7 @@ } fill = POLY.trimTo(fill, slice.tops.map(t => t.poly)); - fill = POLY.union(slice.unioned.appendAll(fill)); + fill = POLY.union(slice.unioned.appendAll(fill),0,true); slice.unioned = fill; }