PIXI.ViewableBuffer
class ViewableBuffer
Flexible wrapper around ArrayBuffer that also provides typed array views on demand.
Constructor
new PIXI.ViewableBuffer(length: number | ArrayBuffer | Uint8Array) → {}
| Name | Type | Description |
|---|---|---|
| length | number | ArrayBuffer | Uint8Array |
The size of the buffer in bytes. |
new PIXI.ViewableBuffer(arrayBuffer: ArrayBuffer) → {}
| Name | Type | Description |
|---|---|---|
| arrayBuffer | ArrayBuffer |
The source array buffer. |
Summary
Properties from ViewableBuffer
| Float32Array |
View on the raw binary data as a |
| Int16Array |
View on the raw binary data as a |
| Int32Array |
View on the raw binary data as a |
| Int8Array |
View on the raw binary data as a |
| ArrayBuffer |
Underlying |
| Uint16Array |
View on the raw binary data as a |
| Uint32Array |
View on the raw binary data as a |
| Uint8Array |
View on the raw binary data as a |
Methods from ViewableBuffer
| void |
Destroys all buffer references. Do not use after calling this. |
| ITypedArray |
|
Public Properties
float32View: Float32Array
View on the raw binary data as a Float32Array.
rawBinaryData: ArrayBuffer
Underlying ArrayBuffer that holds all the data and is of capacity this.size.
uint16View: Uint16Array
View on the raw binary data as a Uint16Array.
uint32View: Uint32Array
View on the raw binary data as a Uint32Array.
Public Methods
destroy() → {void}
Destroys all buffer references. Do not use after calling this.
| Type | Description |
|---|---|
| void |
view(type: string) → {ITypedArray}
Returns the view of the given type.
| Name | Type | Description |
|---|---|---|
| type | string |
One of |
| Type | Description |
|---|---|
| ITypedArray |
|