fix export to grid.print. disable support merge in SLA mode
This commit is contained in:
parent
9d092ad3fe
commit
b090d6f2f5
2 changed files with 27 additions and 27 deletions
|
|
@ -484,29 +484,29 @@ let gs_kiri_sla = exports;
|
|||
return track;
|
||||
}
|
||||
|
||||
let close = [];
|
||||
for (let i=0; i<slice.pillars.length; i++) {
|
||||
let p = slice.pillars[i].point;
|
||||
let d = point.distTo2D(p);
|
||||
// terminate if we're inside another pillar
|
||||
if (d < inc) {
|
||||
track.merged = true;
|
||||
return track;
|
||||
}
|
||||
if (d <= process.slaSupportSize * 1.5) {
|
||||
close.push(p);
|
||||
}
|
||||
}
|
||||
if (close.length) {
|
||||
let newp = point.clone();
|
||||
close.forEach(p => {
|
||||
newp.x += p.x;
|
||||
newp.y += p.y;
|
||||
});
|
||||
newp.x /= (close.length + 1);
|
||||
newp.y /= (close.length + 1);
|
||||
nextpoint = point.offsetPointTo(newp, inc);
|
||||
}
|
||||
// let close = [];
|
||||
// for (let i=0; i<slice.pillars.length; i++) {
|
||||
// let p = slice.pillars[i].point;
|
||||
// let d = point.distTo2D(p);
|
||||
// // terminate if we're inside another pillar
|
||||
// if (d < inc) {
|
||||
// track.merged = true;
|
||||
// return track;
|
||||
// }
|
||||
// if (d <= process.slaSupportSize * 1.5) {
|
||||
// close.push(p);
|
||||
// }
|
||||
// }
|
||||
// if (close.length) {
|
||||
// let newp = point.clone();
|
||||
// close.forEach(p => {
|
||||
// newp.x += p.x;
|
||||
// newp.y += p.y;
|
||||
// });
|
||||
// newp.x /= (close.length + 1);
|
||||
// newp.y /= (close.length + 1);
|
||||
// nextpoint = point.offsetPointTo(newp, inc);
|
||||
// }
|
||||
|
||||
slice.supports.push(pillar);
|
||||
slice.pillars.push({point, pillar, size});
|
||||
|
|
|
|||
Loading…
Reference in a new issue