toArray method

List<num> toArray([
  1. List<double>? array,
  2. int offset = 0
])

Implementation

List<num> toArray([List<double>? array, int offset = 0]) {
  array ??= List<double>.filled(2, 0.0);

  array[offset] = x;
  array[offset + 1] = y;
  return array;
}