From ba51425b01379d3e5abd507f3d8b7769d56eb2c5 Mon Sep 17 00:00:00 2001 From: Bach Le Date: Sat, 6 Feb 2021 23:52:59 +0800 Subject: [PATCH] Fix type annotation for UniformBuffer.set --- build/module/uniform-buffer.js | 2 +- build/types.d.ts | 2 +- src/uniform-buffer.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build/module/uniform-buffer.js b/build/module/uniform-buffer.js index a228c268..e87cbbb6 100644 --- a/build/module/uniform-buffer.js +++ b/build/module/uniform-buffer.js @@ -186,7 +186,7 @@ export class UniformBuffer { @method @param {number} index Index in the layout of item to set. - @param {ArrayBufferView} value Value to store at the layout location. + @param {Array.} value Value to store at the layout location. @return {UniformBuffer} The UniformBuffer object. */ set(index, value) { diff --git a/build/types.d.ts b/build/types.d.ts index 40c193dd..ec8e041d 100644 --- a/build/types.d.ts +++ b/build/types.d.ts @@ -2149,7 +2149,7 @@ export class UniformBuffer { * @param value - Value to store at the layout location. * @returns The UniformBuffer object. */ - set(index: number, value: ArrayBufferView): UniformBuffer; + set(index: number, value: number[]): UniformBuffer; /** * Send stored buffer data to the GPU. * @returns The UniformBuffer object. diff --git a/src/uniform-buffer.js b/src/uniform-buffer.js index a228c268..e87cbbb6 100644 --- a/src/uniform-buffer.js +++ b/src/uniform-buffer.js @@ -186,7 +186,7 @@ export class UniformBuffer { @method @param {number} index Index in the layout of item to set. - @param {ArrayBufferView} value Value to store at the layout location. + @param {Array.} value Value to store at the layout location. @return {UniformBuffer} The UniformBuffer object. */ set(index, value) {