For AI agents: a documentation index is available at /llms.txt. Markdown versions of all pages are available by appending .md to any URL.

Class VertexBuffer

The VertexBuffer class turns a StructArray into a WebGL buffer. Each member of the StructArray's Struct type is converted to a WebGL attribute.

Index

Constructors

Properties

attributes: readonly StructArrayMember[]
buffer: WebGLBuffer
context: Context
dynamicDraw: boolean
itemSize: number
length: number

Methods

  • Returns void

  • Destroy the GL buffer bound to the given WebGL context

    Returns void

  • Set the attribute pointers in a WebGL context

    Parameters

    • gl: WebGL2RenderingContext

      The WebGL context

    • program: Program<any>

      The active WebGL program

    • OptionalvertexOffset: number | null

      Index of the starting vertex of the segment

    Returns void

Was this helpful?