updatePath method

void updatePath(
  1. ScenePath path
)

Re-sweeps the ribbon along path, reusing the GPU buffers.

The width, station count, and alignment are unchanged, so the topology is stable. Requires GeometryStorage.updatable.

Implementation

void updatePath(ScenePath path) {
  final arrays = buildRibbonArrays(
    path,
    width: _width,
    stations: _stations,
    alignment: _alignment,
    up: _up,
  );
  updatePositions(arrays.positions);
  updateNormals(arrays.normals);
  updateTexCoords(arrays.texCoords);
}