diff options
author | Alon Zakai <alonzakai@gmail.com> | 2014-06-17 12:47:36 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2014-06-17 12:47:36 -0700 |
commit | 65b9caa8199b1245cf2e089a5878713569cceeb8 (patch) | |
tree | 3343f695d95f4a69e01d8074b412d88efd84c0f6 /src/webGLWorker.js | |
parent | b2058670260457f310d44999a8b9e842491364ef (diff) |
fix bufferData copying
Diffstat (limited to 'src/webGLWorker.js')
-rw-r--r-- | src/webGLWorker.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/webGLWorker.js b/src/webGLWorker.js index 984c201e..559e13bd 100644 --- a/src/webGLWorker.js +++ b/src/webGLWorker.js @@ -646,7 +646,7 @@ function WebGLWorker() { commandBuffer.push('bindBuffer', 2, target, buffer ? buffer.id : 0); }; this.bufferData = function(target, something, usage) { - if (typeof something !== 'number') something = new Uint8Array(something); + if (typeof something !== 'number') something = new something.constructor(something); commandBuffer.push('bufferData', 3, target, something, usage); }; this.viewport = function(x, y, w, h) { |