Loading video...

Video Failed to Load

Go Home

Now that the latest Chrome version has WebGPU support I guess I can finally talk about this. A year ago David A Roberts and Cornus Ammonis were developing a compute shader based Shadertoy alternative called I already had a lot of fun making some toy projects 😳

125,761 views • 3 years ago •via X (Twitter)

11 Comments

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Of the more interesting things that I did was the Kerr black hole accretion disk simulation

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Another was a forwardly rendered volumetric path tracer (rays go from light source to camera, not the other way around) This one used atomicAdds to rasterize points.

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

And also using the atomic rasterizer I made a cool looking particle demo

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Also a long time ago I did a pet project trying to simulate a nonlinear wave equation in a black hole metric (with questionable results)

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Since this is compute based you can be sure you can make things that go way beyond Shadertoy limitations, so its pretty exciting what people might make here👀 (I'm especially looking forward to algorithms like radix sort, hash grids, building BVH's etc)

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Also don't forget to join the discord in case you have questions

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

Also this thing is open source! (forgot to tell)

Felipe Apablaza's profile picture
Felipe Apablaza3 years ago

@david_ar @cornusammonis WebGPU runs at full native speed? Do you have some metrics of it compared to a desktop equivalent implementation?

END's profile picture
END3 years ago

@Atrix256 @david_ar @cornusammonis yooo @XorDev

Kushiro's profile picture
Kushiro3 years ago

@david_ar @cornusammonis What is the most interesting thing that cannot be done in glsl but do-able in web compute ? Any examples ? 🤔

Mykhailo Moroz's profile picture
Mykhailo Moroz3 years ago

I'd say its more about the scale and performance, than can or can not do. Both are Turing complete after all. For example, with compute you can do a fast radix sort and build an acceleration structure to efficiently find collisions between particles. In WebGL 2.0 you won't be able to use radix sort, bitonic at best, and even that would be way slower compared to pure compute bitonic. Also compute gives random write capability, which makes it easier to implement stuff that might require lots of data per thread. Or scattering operations for example (like custom triangle rasterization). In terms of code stuff there are mainly these differences: a)random read/write, b)atomic operations, c)access to groupshared memory and group barriers

Related Videos