MCPcopy Create free account
hub / github.com/SuperMap/iClient-JavaScript / eliminateHole

Function eliminateHole

libs/mapv/mapv.js:1889–1895  ·  view source on GitHub ↗
(hole, outerNode)

Source from the content-addressed store, hash-verified

1887
1888// find a bridge between vertices that connects hole with an outer ring and and link it
1889function eliminateHole(hole, outerNode) {
1890 outerNode = findHoleBridge(hole, outerNode);
1891 if (outerNode) {
1892 var b = splitPolygon(outerNode, hole);
1893 filterPoints(b, b.next);
1894 }
1895}
1896
1897// David Eberly's algorithm for finding a bridge between hole and outer polygon
1898function findHoleBridge(hole, outerNode) {

Callers 1

eliminateHolesFunction · 0.85

Calls 3

findHoleBridgeFunction · 0.85
splitPolygonFunction · 0.85
filterPointsFunction · 0.85

Tested by

no test coverage detected