MCPcopy Create free account
hub / github.com/microsoft/SandDance / isNestedRingClosed

Function isNestedRingClosed

docs/app/js/sanddance-app.js:103685–103689  ·  view source on GitHub ↗
(simplePolygon)

Source from the content-addressed store, hash-verified

103683 return polygon.length >= 1 && polygon[0].length >= 2 && Number.isFinite(polygon[0][0]);
103684}
103685function isNestedRingClosed(simplePolygon) {
103686 var p0 = simplePolygon[0];
103687 var p1 = simplePolygon[simplePolygon.length - 1];
103688 return p0[0] === p1[0] && p0[1] === p1[1] && p0[2] === p1[2];
103689}
103690function isFlatRingClosed(positions, size, startIndex, endIndex) {
103691 for(var i = 0; i < size; i++){
103692 if (positions[startIndex + i] !== positions[endIndex - size + i]) return false;

Callers 1

copyNestedRingFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected