twgl.js 5.4.0 → 5.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/5.x/twgl-full.d.ts +21 -1
- package/dist/5.x/twgl-full.js +1 -1
- package/dist/5.x/twgl-full.module.js +1 -1
- package/dist/5.x/twgl.js +1 -1
- package/package.json +1 -1
package/dist/5.x/twgl-full.d.ts
CHANGED
|
@@ -3692,7 +3692,25 @@ declare module primitives {
|
|
|
3692
3692
|
/**
|
|
3693
3693
|
* @typedef {(Int8Array|Uint8Array|Int16Array|Uint16Array|Int32Array|Uint32Array|Float32Array)} TypedArray
|
|
3694
3694
|
*/
|
|
3695
|
+
|
|
3695
3696
|
export type TypedArray = Int8Array | Uint8Array | Int16Array | Uint16Array | Int32Array | Uint32Array | Float32Array;
|
|
3697
|
+
|
|
3698
|
+
export type AugmentedTypedArrayHelper = {
|
|
3699
|
+
numComponents: number;
|
|
3700
|
+
readonly numElements: number;
|
|
3701
|
+
/**
|
|
3702
|
+
* Push elements into typed array
|
|
3703
|
+
*/
|
|
3704
|
+
push(...elements: (number | TypedArray | number[])[]): void;
|
|
3705
|
+
/**
|
|
3706
|
+
* Reset push cursor
|
|
3707
|
+
*/
|
|
3708
|
+
reset(index?: number): void;
|
|
3709
|
+
};
|
|
3710
|
+
|
|
3711
|
+
export type AugmentedTypedArray<T extends TypedArray> = T & AugmentedTypedArrayHelper
|
|
3712
|
+
|
|
3713
|
+
|
|
3696
3714
|
/**
|
|
3697
3715
|
* creates a typed array with a `push` function attached
|
|
3698
3716
|
* so that you can easily *push* values.
|
|
@@ -3715,7 +3733,9 @@ declare module primitives {
|
|
|
3715
3733
|
* @return {ArrayBufferView} A typed array.
|
|
3716
3734
|
* @memberOf module:twgl/primitives
|
|
3717
3735
|
*/
|
|
3718
|
-
|
|
3736
|
+
export function createAugmentedTypedArray<T extends TypedArrayConstructor>(numComponents: number, numElements: number, type: T): AugmentedTypedArray<InstanceType<T>>;
|
|
3737
|
+
export function createAugmentedTypedArray<T extends Float32Array>(numComponents: number, numElements: number): AugmentedTypedArray<Float32Array>;
|
|
3738
|
+
|
|
3719
3739
|
/**
|
|
3720
3740
|
* Given indexed vertices creates a new set of vertices un-indexed by expanding the indexed vertices.
|
|
3721
3741
|
* @param {Object.<string, TypedArray>} vertices The indexed vertices to deindex
|
package/dist/5.x/twgl-full.js
CHANGED
package/dist/5.x/twgl.js
CHANGED