Pseudo-fluid Simulation

Share your projects and Chipmunk enhancements.
Post Reply
maximile
Posts: 157
Joined: Mon Aug 20, 2007 12:53 pm
Location: London, UK
Contact:

Pseudo-fluid Simulation

Post by maximile »

http://www.youtube.com/watch?v=V1xiVyJ3EOM

No crazy-cool techniques or anything here, just lots of circles and time. And hardly any friction. Thought you might like to see it.

BTW, it's *not* real time. About 5 or 6 seconds per frame at its slowest. Perhaps not helped by World of Warcraft running in the background, though.
lucas
Posts: 54
Joined: Wed Sep 26, 2007 2:34 am
Contact:

Re: Pseudo-fluid Simulation

Post by lucas »

That is very, very awesome. How big are the circles?
Tangame - a tangram puzzle game with physics.
http://code.google.com/p/tangame/
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: Pseudo-fluid Simulation

Post by slembcke »

Yeah, I've tried something similar. I was definitely impressed that it worked at all to be honest. Simulating water out of little solid circles just doesn't seem like it would work, but it definitely does a pretty good job.

Though it does make me wonder how fast you could get such a thing to run if you simplified the collision detection, and simulated them only as solid particles using vertlet or something. Could be fun to try sometime.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
maximile
Posts: 157
Joined: Mon Aug 20, 2007 12:53 pm
Location: London, UK
Contact:

Re: Pseudo-fluid Simulation

Post by maximile »

The smallest circles are about 0.05 radius, which with my setup corresponds to about 1 pixel. I realise now that I could probably have sped it up if I had set the

Code: Select all

 cpSpaceResizeActiveHash()
accordingly. Oh well.
Ralith
Posts: 2
Joined: Sun Jan 20, 2008 7:06 am
Contact:

Re: Pseudo-fluid Simulation

Post by Ralith »

I'd be really interested to see if this could be optimized to provide a fairly realistic realtime 2D water system.
Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests