SizedPlane constructor

SizedPlane([
  1. double width = 1,
  2. double height = 1
])

Implementation

SizedPlane([
  this.width = 1,this.height= 1
]):super(type: ShapeType.sizedPlane ){
  final double sx = width/2;
  const double sy = 0;
  final double sz = height/2;

  List<Vector3> vertices = [
    Vector3(-sx, sy, -sz),
    Vector3(sx, sy, -sz),
    Vector3(sx, sy, sz),
    Vector3(-sx, sy, sz),
  ];

  const faces = [
    [3, 2, 1, 0]
  ];

  init(vertices, faces);
}