OLDgetChainStartIndices method

List<int> OLDgetChainStartIndices(
  1. List<Coordinate> pts
)

Implementation

List<int> OLDgetChainStartIndices(List<Coordinate> pts) {
  // find the startpoint (and endpoints) of all monotone chains in this edge
  int start = 0;
  List startIndexList = [];
  startIndexList.add(start);
  do {
    int last = findChainEnd(pts, start);
    startIndexList.add(last);
    start = last;
  } while (start < pts.length - 1);
  // copy list to an array of ints, for efficiency
  List<int> startIndex = toIntArray(startIndexList);
  return startIndex;
}