From 29c97a490808b02446ccbd1e950391b9fbd751af Mon Sep 17 00:00:00 2001 From: Stewart Allen Date: Sun, 3 Oct 2021 18:41:58 -0400 Subject: [PATCH] remove ununsed/dead code --- src/geo/polygon.js | 52 ---------------------------------------------- 1 file changed, 52 deletions(-) diff --git a/src/geo/polygon.js b/src/geo/polygon.js index d385064d..2aced57f 100644 --- a/src/geo/polygon.js +++ b/src/geo/polygon.js @@ -69,58 +69,6 @@ const PRO = Polygon.prototype; - /** ****************************************************************** - * Polygon Filter/Chain Functions - ******************************************************************* */ - - Polygon.filterTooSmall = function(p) { - return p.length < 3 ? null : p; - }; - - Polygon.filterTooSkinny = function(p) { - return (p.circularityDeep() * p.areaDeep()) < 0.25 ? null : p; - }; - - Polygon.filterArea = function(area) { - return function(p) { - return p.area() >= area ? p : null; - }; - }; - - Polygon.filterDeleted = function(p) { - return p.delete ? null : p; - }; - - Polygon.filterInside = function(pin) { - return function(p) { - return pin.contains(p); - } - }; - - Polygon.filterCollect = function(out) { - return function(p) { - out.push(p); - return p; - } - }; - - Polygon.filterEvolve = function(p) { - return p.evolve(); - }; - - Polygon.filterChain = function(filters) { - return function() { - let f = filters; - return function(p) { - let len = f.length, - idx = 0; - while (idx < len && (p = f[idx++](p))) - ; - return p; - } - }(); - }; - Polygon.fromArray = function(array) { return newPolygon().fromArray(array); };