setup for segmenting first layer tops

This commit is contained in:
Stewart Allen 2019-06-28 12:47:45 -04:00
commit 7c568bfcbf
2 changed files with 11 additions and 3 deletions

View file

@ -390,6 +390,13 @@ var gs_kiri_slice = exports;
opt = options || {}; opt = options || {};
slice.tops.forEach(function(top) { slice.tops.forEach(function(top) {
var top_poly = [ top.poly ];
if (slice.index === 0) {
// console.log({slice_top_0: top_poly, count});
// segment polygon
}
if (opt.vase) { if (opt.vase) {
top.poly = top.poly.clone(false); top.poly = top.poly.clone(false);
} }
@ -406,14 +413,14 @@ var gs_kiri_slice = exports;
if (count) { if (count) {
// permit offset of 0 for laser // permit offset of 0 for laser
if (offset1 === 0) { if (offset1 === 0) {
last = [top.poly].clone(true); last = top_poly.clone(true);
top.traces = last; top.traces = last;
} else { } else {
if (opt.thin) { if (opt.thin) {
var on1s2 = offset1 * 2, var on1s2 = offset1 * 2,
on2s2 = offsetN * 2; on2s2 = offsetN * 2;
POLY.expand2( POLY.expand2(
[top.poly], top_poly,
-offset1, -offset1,
-offsetN, -offsetN,
top.traces, top.traces,
@ -452,7 +459,7 @@ var gs_kiri_slice = exports;
z); z);
} else { } else {
POLY.expand( POLY.expand(
[top.poly], top_poly,
-offset1, -offset1,
z, z,
top.traces, top.traces,

View file

@ -14,6 +14,7 @@
# FDM todo # FDM todo
* first layer segment large flat areas for better fill reliability
* adaptive column to compensate for fine or layers that finish too quickly and melt * adaptive column to compensate for fine or layers that finish too quickly and melt
* apply finish speed to exposed top and underside flat areas * apply finish speed to exposed top and underside flat areas
* store/recover grid:print target against printer selected in device * store/recover grid:print target against printer selected in device