Skip to main content

VertexLayoutOptions

Index

Properties

attributes

attributes: [name: string, numberOfComponents: number][]

Specify the attributes that will exist in the vertex buffer

Important must specify them in the order that they will be in the vertex buffer!!

gl

gl: WebGL2RenderingContext

WebGL2RenderingContext this layout will be attached to, these cannot be reused across contexts.

optionalshader

shader?: Shader

Shader that this layout will be for, if null you must set a shader before using it.

optionalsuppressWarnings

suppressWarnings?: boolean

Optionally suppress any warnings out of vertex layouts

BEWARE this may cause you to have issues go unnoticed

vertexBuffer

vertexBuffer: VertexBuffer

Vertex buffer to use for vertex data