Class PrimitiveCylinder

A simple cylinder primitive with a given radius, height and subdivisions

Hierarchy (View Summary)

Constructors

Properties

Accessors

Methods

Constructors

  • Create a new cylinder primitive

    Parameters

    • gl: WebGL2RenderingContext

      WebGL2RenderingContext

    • radius: number

      Radius of the cylinder

    • height: number

      Height of the cylinder

    • subdivisionsR: number

      Subdivisions around the cylinder

    • subdivisionsV: number

      Subdivisions vertically

    • caps: boolean

      Should the cylinder have caps

    Returns PrimitiveCylinder

Properties

bufferInfo: undefined | BufferInfo
caps: boolean
material: Material
triangles: number

Accessors

Methods

  • Render is used draw this primitive, this is called from the Instance that wraps this renderable.

    Parameters

    • gl: WebGL2RenderingContext
    • uniforms: UniformSet
    • OptionalmaterialOverride: Material
    • OptionalprogramOverride: ProgramInfo

    Returns void