fix buffer geometry call from recent threejs upgrade. also typo fix in polygons
This commit is contained in:
parent
fd86b9b93a
commit
d1f234fb61
2 changed files with 2 additions and 3 deletions
|
|
@ -49,7 +49,6 @@ const POLYS = base.polygons = {
|
||||||
offset,
|
offset,
|
||||||
trimTo,
|
trimTo,
|
||||||
expand,
|
expand,
|
||||||
// expand_lines,
|
|
||||||
points,
|
points,
|
||||||
length,
|
length,
|
||||||
route,
|
route,
|
||||||
|
|
@ -776,7 +775,7 @@ function fillArea(polys, angle, spacing, output, minLen, maxLen) {
|
||||||
if (clip.Execute(ClipIntersect, tree, FillNonZero, FillEvenOdd)) {
|
if (clip.Execute(ClipIntersect, tree, FillNonZero, FillEvenOdd)) {
|
||||||
for (let poly of tree.m_AllPolys) {
|
for (let poly of tree.m_AllPolys) {
|
||||||
if (minlen || maxlen) {
|
if (minlen || maxlen) {
|
||||||
let plen = clib.JS.PerimeterOfPath(poly.m_polygon, false, 1);
|
let plen = ClipperLib.JS.PerimeterOfPath(poly.m_polygon, false, 1);
|
||||||
if (minlen && plen < minlen) continue;
|
if (minlen && plen < minlen) continue;
|
||||||
if (maxlen && plen > maxlen) continue;
|
if (maxlen && plen > maxlen) continue;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -273,7 +273,7 @@ FDM.init = function(kiri, api) {
|
||||||
// eliminate / normalize uv to allow other widget merge
|
// eliminate / normalize uv to allow other widget merge
|
||||||
box.setAttribute('uv',new BufferAttribute(new Float32Array(0), 3));
|
box.setAttribute('uv',new BufferAttribute(new Float32Array(0), 3));
|
||||||
}
|
}
|
||||||
let bbg = BufferGeometryUtils.mergeBufferGeometries(boxen);
|
let bbg = BufferGeometryUtils.mergeGeometries(boxen);
|
||||||
let sw = kiri.newWidget(null, group);
|
let sw = kiri.newWidget(null, group);
|
||||||
let fwp = group[0].track.pos;
|
let fwp = group[0].track.pos;
|
||||||
sw.loadGeometry(bbg);
|
sw.loadGeometry(bbg);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue