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

Function indexCurve

docs/app/js/sanddance-app.js:101944–101955  ·  view source on GitHub ↗
(start, minX, minY, invSize)

Source from the content-addressed store, hash-verified

101942 return area(m.prev, m, p.prev) < 0 && area(p.next, m, m.next) < 0;
101943}
101944function indexCurve(start, minX, minY, invSize) {
101945 let p = start;
101946 do {
101947 if (p.z === null) p.z = zOrder(p.x, p.y, minX, minY, invSize);
101948 p.prevZ = p.prev;
101949 p.nextZ = p.next;
101950 p = p.next;
101951 }while (p !== start);
101952 p.prevZ.nextZ = null;
101953 p.prevZ = null;
101954 sortLinked(p);
101955}
101956function sortLinked(list) {
101957 let e;
101958 let i;

Callers 1

earcutLinkedFunction · 0.70

Calls 2

zOrderFunction · 0.70
sortLinkedFunction · 0.70

Tested by

no test coverage detected