Cylinder constructor

Cylinder(
  1. ShapeConfig config,
  2. double radius,
  3. double height
)

Cylinder shape

config configuration of the shape

radius the top and bottom radius of the cylinder

height the height of the cylinder

Implementation

Cylinder(ShapeConfig config, this.radius, this.height ):super(config) {
  type = Shapes.cylinder;
  halfHeight = height * 0.5;
}