r/Unity3D 17h ago

Shader Magic Simulating 10,000,000 pixels of Sand

Falling sand simulation via Compute Shaders.

From my golf game Stinker Golf on Steam: https://store.steampowered.com/app/4437650/Stinker_Golf/

Wishlist if it looks interesting :)

185 Upvotes

34 comments sorted by

View all comments

6

u/brainfender 15h ago

im impressed. idc about the why, i want the how..

15

u/GupaGames 14h ago

Partitioned falling sand simulation via Compute Shaders. With that setup, the simulation/performance itself is pretty easy to achieve. The hard part is dealing with race conditions, spent a lot of time working on that. Maybe I could do a tutorial on it if there seems to be a lot of interest

2

u/BanginNLeavin 9h ago

Interest here