Got really curious about Realtime Fluid Simulations and I put together this video that will hopefully help you understand how it all works, the core technology used is Smoothed Particle Hydrodynamics, and everything is written from scratch in Unity using C# and Compute Shaders.
If this video gains some interest I'll release a second part about optimization and making the fluid look cooler, just leave a comment down below if you're interested.
Also tried a new editing style, and would love some feedback. It's been a while since I released a video so thanks to everyone who's supported me so far :)
I'll see you all next time ✌
---
Project Links
---
GitHub: github.com/AJTech2002/SPH-Uni...
Base Project: github.com/AJTech2002/SPH-Uni...
FluidRayMarching.cs : github.com/AJTech2002/SPH-Uni...
---
Information Links
---
SPH Paper: matthias-research.github.io/p...
Sebastian Lague Raymarching: • Coding Adventure: Ray ...
Thread Groups Medium Article: / compute-shader-indices
---
Timestamps
---
Intro: (0:00)
SPH Explanation: (0:45)
Project Setup: (4:22)
Initializing Particles: (5:03)
Compute Shader Setup: (9:24)
Integrate Function: (10:33)
Linking Compute Shader: (12:09)
Density & Pressure Calculation: (14:13)
Force Calculations: (16:45)
Testing: (20:25)
External Forces: (21:07)
Raymarching Setup: (21:48)
Outro: (22:43)
25 июл 2024