Shaku

Shaku JS

Back To Table of Content

Mesh

Mesh

Class to hold a mesh.

Kind: global class

new Mesh(positions, textureCoords, colorss, indices, indicesCount)

Create the mesh object.

Param Type Description
positions WebGLBuffer vertices positions buffer.
textureCoords WebGLBuffer vertices texture coords buffer.
colorss WebGLBuffer vertices colors buffer.
indices WebGLBuffer indices buffer.
indicesCount Number how many indices we have.

mesh.overrideColors(gl, color)

Override the colors buffer, if possible.

Kind: instance method of Mesh

Param Type Description
gl WebGl WebGL context.
color Color Color to set.