Webgl points / get back the instructions array from the worker

This means we won't have to recreate a binary buffer (through a typed array)
on every `rebuildBuffer` call.
This commit is contained in:
Olivier Guyot
2019-05-16 23:10:16 +02:00
parent 65be907095
commit 8566cfc227
2 changed files with 4 additions and 1 deletions

View File

@@ -30,8 +30,9 @@ onmessage = event => {
type: 'buffers-generated',
vertexBuffer: vertexBuffer.buffer,
indexBuffer: indexBuffer.buffer,
renderInstructions: renderInstructions.buffer,
projectionTransform
}, [vertexBuffer.buffer, indexBuffer.buffer]);
}, [vertexBuffer.buffer, indexBuffer.buffer, renderInstructions.buffer]);
}
};