indexCurve function

void indexCurve(
  1. Node start,
  2. dynamic minX,
  3. dynamic minY,
  4. dynamic invSize,
)

Implementation

void indexCurve(Node start, minX, minY, invSize) {
  var p = start;
  do {
    p.z ??= zOrder(p.x, p.y, minX, minY, invSize).toDouble();
    p.prevZ = p.prev;
    p.nextZ = p.next;
    p = p.next!;
  } while (p != start);

  p.prevZ!.nextZ = null;
  p.prevZ = null;

  sortLinked(p);
}