Contents

generateCone(height:radius:)

Creates a new cone mesh with the specified dimensions.

Declaration

@MainActor @preconcurrency static func generateCone(height: Float, radius: Float) -> MeshResource

Parameters

  • height:

    The height of the cone, in meters, along the y-axis.

  • radius:

    The base radius of the cone, in meters.

Discussion

The cone is centered at the local origin with its axis aligned along the y-axis.

See Also

Creating a primitive shape