improve retraction over inner voids
This commit is contained in:
parent
8ecc974fcf
commit
0bdbf74312
3 changed files with 9 additions and 11 deletions
|
|
@ -484,8 +484,6 @@ var gs_kiri_print = exports;
|
|||
minSeek = nozzle * (opt.minSeek || 1.5),
|
||||
thinWall = nozzle * (opt.thinWall || 1.75),
|
||||
retractDist = opt.retractOver || 2,
|
||||
retractDistFill = opt.retractOverSparse || 10,
|
||||
retractDistSparse = opt.retractOverSparse || 5,
|
||||
fillMult = opt.mult || process.outputFillMult,
|
||||
shellMult = opt.mult || process.outputShellMult || (process.laserSliceHeight >= 0 ? 1 : 0),
|
||||
sparseMult = process.outputSparseMult,
|
||||
|
|
@ -513,8 +511,8 @@ var gs_kiri_print = exports;
|
|||
|
||||
function intersectsTop(p1, p2) {
|
||||
var int = false;
|
||||
slice.tops.forEach(function(top) {
|
||||
if (!int) top.poly.forEachSegment(function(s1, s2) {
|
||||
POLY.flatten(slice.gatherTopPolys([])).forEach(function(poly) {
|
||||
if (!int) poly.forEachSegment(function(s1, s2) {
|
||||
if (UTIL.intersect(p1,p2,s1,s2,BASE.key.SEGINT)) {
|
||||
int = true;
|
||||
return int;
|
||||
|
|
@ -558,7 +556,7 @@ var gs_kiri_print = exports;
|
|||
if (poly.last() === point) poly.reverse();
|
||||
poly.forEachPoint(function(p, i) {
|
||||
// retract if dist trigger and crosses a slice top polygon
|
||||
if (i === 0 && lp && lp.distTo2D(p) > retractDistSparse && intersectsTop(lp,p)) {
|
||||
if (i === 0 && lp && lp.distTo2D(p) > retractDist && intersectsTop(lp,p)) {
|
||||
retract();
|
||||
}
|
||||
addOutput(preout, p, i === 0 ? 0 : sparseMult, printSpeed);
|
||||
|
|
@ -608,7 +606,7 @@ var gs_kiri_print = exports;
|
|||
lastout = 1;
|
||||
} else {
|
||||
// retract if dist trigger or crosses a slice top polygon
|
||||
if (dist > retractDistFill || intersectsTop(startPoint, p1)) {
|
||||
if (dist > retractDist && intersectsTop(startPoint, p1)) {
|
||||
retract();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -2426,10 +2426,6 @@ self.kiri.license = exports.LICENSE;
|
|||
outputSparseMult: UC.newInput("infill factor", {title:"extrusion multiplier\n0.0 - 2.0", convert:UC.toFloat, bound:UC.bound(0.0,2.0), modes:FDM}),
|
||||
outputCooling: UC.newBoolean("cooling", onBooleanClick, {title: "enable cooling fan\nafter first layer", modes:FDM}),
|
||||
|
||||
output: UC.newGroup("raft"),
|
||||
outputRaftSpacing: UC.newInput("spacing", {title:"additional layer spacing\nbetween 1st layer and raft\nin millimeters", convert:UC.toFloat, bound:UC.bound(0.0,3.0), modes:FDM}),
|
||||
outputRaft: UC.newBoolean("enable", onBooleanClick, {title:"create a raft under the\nmodel for better adhesion\nuses skirt offset and\ndisables skirt output", modes:FDM}),
|
||||
|
||||
// cam
|
||||
camTolerance: UC.newInput("tolerance", {title:"surface precision\nin millimeters", convert:UC.toFloat, bound:UC.bound(0.05,1.0), modes:CAM}),
|
||||
camZTopOffset: UC.newInput("z top offset", {title:"offset from stock surface\nto top face of part\nin millimeters", convert:UC.toFloat, modes:CAM}),
|
||||
|
|
@ -2466,6 +2462,10 @@ self.kiri.license = exports.LICENSE;
|
|||
sliceSupportExtra: UC.newInput("expand", {title:"expand support area\nbeyond part boundary\nin millimeters", bound:UC.bound(0.0,200.0), convert:UC.toFloat, modes:FDM}),
|
||||
sliceSupportEnable: UC.newBoolean("enable", onBooleanClick, {modes:FDM}),
|
||||
|
||||
output: UC.newGroup("raft"),
|
||||
outputRaftSpacing: UC.newInput("spacing", {title:"additional layer spacing\nbetween 1st layer and raft\nin millimeters", convert:UC.toFloat, bound:UC.bound(0.0,3.0), modes:FDM}),
|
||||
outputRaft: UC.newBoolean("enable", onBooleanClick, {title:"create a raft under the\nmodel for better adhesion\nuses skirt offset and\ndisables skirt output", modes:FDM}),
|
||||
|
||||
advanced: UC.newGroup("advanced", null, {modes:FDM}),
|
||||
// outputRetractOver: UC.newInput("retract over", {title:"move threshold that\ntriggers retraction\n0 to disable", convert:UC.toFloat, modes:FDM}),
|
||||
outputRetractDist: UC.newInput("retract dist", {title:"amount to retract filament", convert:UC.toFloat, modes:FDM}),
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
var exports = {
|
||||
COPYRIGHT:"Copyright (C) 2014-2017 Stewart Allen <stewart@neuron.com> - All Rights Reserved",
|
||||
LICENSE:"Unauthorized copying, modification and re-distribution are strictly prohibited without prior written consent.",
|
||||
VERSION:"1.0.92"
|
||||
VERSION:"1.0.93"
|
||||
};
|
||||
if (!module) var module = {};
|
||||
module.exports = exports;
|
||||
|
|
|
|||
Loading…
Reference in a new issue