Skip to content

Commit

Permalink
feat: Add texture.clone() support and tests
Browse files Browse the repository at this point in the history
feat: Upgrade gpu-mock.js
fix: Typescript `Texture` definition
fix: Typescript JSON definition
fix: Some internal documentation
fix: Some removal of unused or duplicate code
  • Loading branch information
robertleeplummerjr committed Oct 13, 2019
1 parent 33a2395 commit ab75103
Show file tree
Hide file tree
Showing 22 changed files with 1,283 additions and 1,409 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ NOTE: documentation is slightly out of date for the upcoming release of v2. We
* [Types](#types)
* [Loops](#loops)
* [Pipelining](#pipelining)
* [Cloning Textures](#cloning-textures)
* [Offscreen Canvas](#offscreen-canvas)
* [Cleanup](#cleanup)
* [Flattened typed array support](#flattened-typed-array-support)
Expand Down Expand Up @@ -712,6 +713,9 @@ const matMult = gpu.createKernel(function(a, b) {
[Pipeline](https://en.wikipedia.org/wiki/Pipeline_(computing)) is a feature where values are sent directly from kernel to kernel via a texture.
This results in extremely fast computing. This is achieved with the kernel setting `pipeline: boolean` or by calling `kernel.setPipeline(true)`

### Cloning Textures **New in V2!**
When using pipeline mode the outputs from kernels can be cloned using `texture.clone()`.

```js
const kernel1 = gpu.createKernel(function(v) {
return v[this.thread.x];
Expand Down
Loading

0 comments on commit ab75103

Please sign in to comment.