fix corner case w/ tabs and selected ops
This commit is contained in:
parent
a3487f96a8
commit
719cc125f7
1 changed files with 10 additions and 4 deletions
|
|
@ -707,8 +707,8 @@ var gs_kiri_cam = exports;
|
||||||
pocketOnlyRough = outp.camPocketOnlyRough,
|
pocketOnlyRough = outp.camPocketOnlyRough,
|
||||||
pocketOnlyFinish = outp.camPocketOnlyFinish,
|
pocketOnlyFinish = outp.camPocketOnlyFinish,
|
||||||
// addTabs = proc.camTabsOn && !pocketOnly,
|
// addTabs = proc.camTabsOn && !pocketOnly,
|
||||||
addTabsRough = proc.camTabsOn && !pocketOnlyRough,
|
addTabsRough = procRough && proc.camTabsOn && !pocketOnlyRough,
|
||||||
addTabsFinish = proc.camTabsOn && !pocketOnlyFinish,
|
addTabsFinish = anyFinish && proc.camTabsOn && !pocketOnlyFinish,
|
||||||
tabWidth = proc.camTabsWidth,
|
tabWidth = proc.camTabsWidth,
|
||||||
tabHeight = proc.camTabsHeight,
|
tabHeight = proc.camTabsHeight,
|
||||||
mesh = widget.mesh,
|
mesh = widget.mesh,
|
||||||
|
|
@ -766,8 +766,14 @@ var gs_kiri_cam = exports;
|
||||||
var lrtop = trace.intersections(htl, htr),
|
var lrtop = trace.intersections(htl, htr),
|
||||||
lrbot = trace.intersections(hbl, hbr),
|
lrbot = trace.intersections(hbl, hbr),
|
||||||
tblt = trace.intersections(vtl, vbl),
|
tblt = trace.intersections(vtl, vbl),
|
||||||
tbrt = trace.intersections(vtr, vbr),
|
tbrt = trace.intersections(vtr, vbr);
|
||||||
tr1 = trace.emitSegment(lrtop[0], tblt[0]),
|
|
||||||
|
if (!(lrtop.length && lrbot.length && tblt.length && tbrt.length)) {
|
||||||
|
console.log("unable to compute cutouts");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
var tr1 = trace.emitSegment(lrtop[0], tblt[0]),
|
||||||
tr2 = trace.emitSegment(tbrt[0], lrtop[lrtop.length-1]),
|
tr2 = trace.emitSegment(tbrt[0], lrtop[lrtop.length-1]),
|
||||||
tr3 = trace.emitSegment(lrbot[lrbot.length-1], tbrt[tbrt.length-1]),
|
tr3 = trace.emitSegment(lrbot[lrbot.length-1], tbrt[tbrt.length-1]),
|
||||||
tr4 = trace.emitSegment(tblt[tblt.length-1], lrbot[0]);
|
tr4 = trace.emitSegment(tblt[tblt.length-1], lrbot[0]);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue