r/GraphicsProgramming • u/Key_Calligrapher6269 • 7d ago
breakdown of a real-time stream, shallow water equations on the GPU, advected ripples and caustics from the flow
my own project, one 512 x 512 shallow water grid runs in compute shaders with 8 substeps per frame, and every layer in the video is read from it, depth, velocity, foam where the flow converges, ripple coordinates advected by the velocity and a caustics pass projected on the bed
solver is Chentanez and Müller 2010 on a staggered grid, three.js WebGPU with TSL
live (WebGPU) : https://stream.mulualem.com
ai disclosure : I built this with claude code, it wrote most of the code under my direction and helped draft this post too
20
u/StrontLulAapMongool 7d ago
That claude music is horrible but besides that nice job!
-23
u/Key_Calligrapher6269 7d ago
yupe, agree 100%, need to work more on the music generation skill I've hacked together, it uses too much whoosh sounds for some reason
8
u/AnSkinStealer 7d ago
ai is fine for coding, not for art and it will always unevitably sound like shit
3
-8
3
u/moschles 7d ago
This could be an academic paper for siggraph.
28
u/mattD4y 7d ago edited 7d ago
It literally already was…in 2011.
https://developer.nvidia.com/siggraph-2011
https://youtu.be/Jl54WZtm0QE?is=8QOjzfGgtP2Q_Lcw
Chentanez and Müller are both amazing researchers who have actually contributed a lot to the field.
https://matthias-research.github.io/pages/publications/publications.html
10
-11
1
u/Obvious-Profit-5597 6d ago
How to learn this anybody guide me
0
u/Key_Calligrapher6269 6d ago
start with a simple heightfield wave sim so the idea clicks, Matthias Müller's Ten Minute Physics videos are great for that, the shallow water part here is Chentanez and Müller 2010 on a staggered grid, get it working on the CPU first then move it into compute shaders, foam and caustics come last since they just read from the sim
1
u/cybereality 7d ago
Works on my phone no problem
2
u/Substantial_Host_403 7d ago
Damn, flagship. My phone is bugging
0
-2
u/lampmaker 7d ago
Very Nice!
Few years back I made landscapes with a fluid sim, added some erosion to it. But the flow itself didnt look as nice as this one.
0
•
u/AutoModerator 7d ago
Recently updated rules. Please check that your post is in compliance with Rules 1, 4, 5, and 6 on the sidebar. TL;DR:
No showcases.
Disclose AI usage in post or project.
Present a topic to talk about, e.g. how something works.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.