Engine API Reference - v2.6.1
    Preparing search index...

    Class CylinderGeometry

    A procedural cylinder-shaped geometry.

    The size, shape and tesselation properties of the cylinder can be controlled via constructor parameters. By default, the function will create a cylinder standing vertically centered on the XZ-plane with a radius of 0.5, a height of 1.0, 1 height segment and 20 cap segments.

    Note that the cylinder is created with UVs in the range of 0 to 1.

    Hierarchy

    • ConeBaseGeometry
      • CylinderGeometry
    Index

    Constructors

    • Create a new CylinderGeometry instance.

      Parameters

      • Optionalopts: {
            calculateTangents?: boolean;
            capSegments?: number;
            height?: number;
            heightSegments?: number;
            radius?: number;
        } = {}

        An object that specifies optional inputs for the function as follows:

        • OptionalcalculateTangents?: boolean

          Generate tangent information (defaults to false).

        • OptionalcapSegments?: number

          The number of divisions around the tubular body of the cylinder (defaults to 20).

        • Optionalheight?: number

          The length of the body of the cylinder (defaults to 1.0).

        • OptionalheightSegments?: number

          The number of divisions along the length of the cylinder (defaults to 5).

        • Optionalradius?: number

          The radius of the tube forming the body of the cylinder (defaults to 0.5).

      Returns CylinderGeometry

    Properties

    blendIndices: undefined | number[]

    Blend indices.

    blendWeights: undefined | number[]

    Blend weights.

    colors: undefined | number[]

    Colors.

    Methods

    • Generates normal information from the positions and triangle indices.

      Returns void

    • Generates tangent information from the positions, normals, texture coordinates and triangle indices.

      Returns void