I think this uses Canvas/WebGL to provoke the GPU into performing calculations behind the scenes. If that's true, I imagine this solution will fall by the wayside as WebGPU becomes production ready.
It should. Then again WebCl existed 10 years ago to solve this problem but never took off because you needed vendor support for each device. So hacks like mapping matrix math to textures and back again is much more likely to work on the widest number of devices, which is why you see these libraries. With W3C support, JS GPU programming should be built into web browsers and we shouldn’t need such hacks to build high performance web apps.
There's a long tradition on the web of bundling various implementations of an emerging feature under a library that can automatically pick the best one for the platform it's running on. Usually these act as temporary scaffolding until the browser-sanctioned API becomes ubiquitous, at which point they're phased out
From what I remember Intel failed at least twice to make it happen with compute shaders.
First they had a kind of OpenCL plugin, which died when plugins got widespread killed.
Then they finally managed to ramp enough quorum to add OpenGL compute shaders to WebGL 2.0, as an extension, just to have Google killing the efforts with "compute on the Web should be done via WebGPU".
So now it is time to wait again, until WebGPU actually makes it.
I checked, "Get WebGPU as an alternate backend (help wanted)"
> We need this [WebGPU] in GPU.js, possibly as a sub-project: https://github.com/maierfelix/webgpu
Once it becomes stable, and well supported and tested, we could possibly make it the default fallback.
Which looking to the 10 years that took for WebGL 2.0 to finally become available everywhere, and WGSL is still half baked, being production ready is still a couple of years away.
Your comment probably got downed more drastically than normal for being a new account but on the off chance you're a legitimate new account that just had an unlucky first comment:
I also felt that it could be made clearer on the web page that it works on both node js and the web. Right now it could be interpreted as both or only node.