C4 Engine
C4 Engine API Documentation

class TorusGeometry

Defined in:  C4Primitives.h
The TorusGeometry class represents a torus primitive node in a world.
Definition

class TorusGeometry final : public PrimitiveGeometry

Constructor

TorusGeometry(const Vector2D& primary, float secondary);

Parameters
primary The primary size of the torus.
secondary The secondary radius of the torus.
Description
The TorusGeometry class represents a torus primitive node in a world. In its local coordinate space, a torus primitive has its center at the origin. The components of the primary parameter define the primary semiaxis lengths of the torus in the x-y plane, and the secondary parameter defines the secondary radius of the torus about the primary ring.

When a new torus geometry is created, the corresponding TorusGeometryObject is automatically created and referenced by the geometry node.
Base Classes
PrimitiveGeometry A torus is a specific type of primitive geometry.
See Also

TorusGeometryObject