fix polygon perimeter() and restore gyroid filter
This commit is contained in:
parent
e45d177cf8
commit
f12b3f2e9f
2 changed files with 2 additions and 2 deletions
|
|
@ -1338,7 +1338,7 @@
|
|||
* @returns {number} perimeter length (sum of all segment lengths)
|
||||
*/
|
||||
PRO.perimeter = function() {
|
||||
if (this.perim !== 0.0) {
|
||||
if (this.perim) {
|
||||
return this.perim;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@
|
|||
}
|
||||
}
|
||||
polys = connectOpenPolys(polys);
|
||||
for (let poly of polys) {
|
||||
for (let poly of polys.filter(p => p.perimeter() > 2)) {
|
||||
target.newline();
|
||||
for (let point of poly.points) {
|
||||
target.emit(point.x, point.y);
|
||||
|
|
|
|||
Loading…
Reference in a new issue