FastSphere3D constructor

FastSphere3D(
  1. double radius,
  2. Vector3 position, {
  3. Color? color,
})

Implementation

FastSphere3D(this.radius, this.position, {this.color}) {
  final sphere = SphereGenerator();
  final mesh = sphere.createSphere(radius, latSegments: 5, lonSegments: 5);
  sphereVertices = (mesh.getViewForAttrib('POSITION')! as Vector3List);
  indices = mesh.indices!;

  sphereVertices + vm.Vector3(position.x, position.y, position.z);
}