torus

fun torus(radius: Float, size: Float, radSeg: Int, sides: Int): Mesh

Generates a torus mesh.

Return

The generated mesh.

Parameters

radius

The radius of the torus.

size

The size of the torus tube.

radSeg

The number of segments around the main radius. Increasing the number of segments increases the number of subdivisions around the main radius, which improves the torus's roundness.

sides

The number of sides of the torus tube. Increasing the number of sides increases the number of subdivisions around the tube, which improves the torus's roundness.