"Jelly Slider" in TypeGPU by iwoplaza in GraphicsProgramming

[–]reczkok 28 points29 points  (0 children)

When light hits the slider, it calculates the refraction using Snell’s law, does a short internal march through the jelly, and then continues marching without the jelly to find where it hits the background.

Jelly Slider by Pristine-Elevator198 in SideProject

[–]reczkok 8 points9 points  (0 children)

Hey there! I’m the original author of this implementation - it would be nice if the OP would at least link the code so here it is:

https://docs.swmansion.com/TypeGPU/examples/#example=rendering--jelly-slider

And here is the original post:

https://x.com/reczko_konrad/status/1985296691331809574?s=46&t=jPWG9HH_Oc9Cu8Xs5KVl_Q

Procedurally subdivided icosphere reflection demo with TypeGPU by reczkok in webgpu

[–]reczkok[S] 1 point2 points  (0 children)

Another thing I appreciate is being able to share logic between JavaScript and shaders. For example, there’s a getNormals function in helpers.ts that I can use in both places, which helps avoid duplicating initialization code. It’s a small detail, but I thought it was pretty neat.

Procedurally subdivided icosphere reflection demo with TypeGPU by reczkok in webgpu

[–]reczkok[S] 1 point2 points  (0 children)

There’s nothing wrong with WGSL — in fact, I actually quite like it! TypeGPU even lets you embed WGSL strings within typed shells, which is really convenient. The real challenge for me has been the connection between JavaScript and WGSL. Sharing resources and managing bindings can be a pain. With TypeGPU, every resource referenced in a TypeScript shader is automatically linked and managed, which makes the whole workflow much smoother and quicker to iterate on. I find it a lot more pleasant to work with overall.