class VertexBuffer
Name | Type | Description | |
---|---|---|---|
engine | any | ||
data | FloatArray or Buffer | ||
kind | string | ||
updatable | boolean | ||
optional | postponeInternalCreation | boolean | |
optional | stride | number | |
optional | instanced | boolean | |
optional | offset | number |
Returns the kind of the VertexBuffer (string).
Boolean : is the VertexBuffer updatable ?
Returns an array of numbers or a Float32Array containing the VertexBuffer data.
Returns the WebGLBuffer associated to the VertexBuffer.
Returns the stride of the VertexBuffer (integer).
Returns the offset (integer).
Returns the VertexBuffer total size (integer).
Boolean : is the WebGLBuffer of the VertexBuffer instanced now ?
Returns the instancing divisor, zero for non-instanced (integer).
Creates the underlying WebGLBuffer from the passed numeric array or Float32Array.
Returns the created WebGLBuffer.
Name | Type | Description | |
---|---|---|---|
optional | data | FloatArray |
Updates the underlying WebGLBuffer according to the passed numeric array or Float32Array.
Returns the updated WebGLBuffer.
Name | Type | Description | |
---|---|---|---|
data | FloatArray |
Updates directly the underlying WebGLBuffer according to the passed numeric array or Float32Array.
Returns the directly updated WebGLBuffer.
Name | Type | Description | |
---|---|---|---|
data | Float32Array | ||
offset | number |
Disposes the VertexBuffer and the underlying WebGLBuffer.