generateIndices method

  1. @override
void generateIndices(
  1. Uint16List indices
)
override

Implementation

@override
void generateIndices(Uint16List indices) {
  var index = 0;
  final length = _segments * 2;
  for (var i = 0; i < length; i += 2) {
    indices[index + 0] = i + 0;
    indices[index + 1] = i + 1;
    indices[index + 2] = i + 3;
    indices[index + 3] = i + 0;
    indices[index + 4] = i + 3;
    indices[index + 5] = i + 2;
    index += 6;
  }
  assert(index == indexCount);
}