Wednesday, December 2, 2009

Yet more progress on soft-body physics

Hopefully this is going to be the last update to my soft-body physics engine... I can't think of any ways to make it more realistic and efficient. Right now I'm very pleased with the effect. It's not completely accurate, but it looks very natural compared to some of the other engines I've seen on the web.

In this version, I introduced a concept of 'ambient force' which works on the same premise as 'ambient light' for people who are familiar with 3D. The reason for ambient light is that it would be too computationally expensive to simulate light beams bouncing around surfaces millions of times just to make things look natural; it's must better to just reproduce the effect of the physics as opposed to the physics itself.

Ambient force was made to simulate the effect of inter-molecular bonds that cause a molecule to pull its neighbors when a force is exerted upon that molecule. Instead of going through each point in the deformable body and simulating the effect of the bonds with its neighbors, I thought it would be much easier to just apply a scaled ambient force to every particle in the system; the closer it is to the center of mass, the less ambient force is applied (again this is because of the 'normal' force discussed in my previous post).

Anyway, here's the result:

No comments:

Post a Comment