Self-collision in cloth simulation

Started by
3 comments, last by oliii 19 years, 7 months ago
Hi. I have some pretty fast cloth simulation code, and I would like to update it adding collision detection and, if possible, self-collision. Does anyone know of a fast method for self-collision detection and avoidance in cloth? Thanks in advance. Cheers, Angel
Advertisement
I am mildly interested in this, as a feature to be implemented, so I'll try to keep the discussion going.

I think the method is gonna be inherently slow, whatever it is :)

you might find this interesting though.

http://ligwww.epfl.ch/~thalmann/papers.dir/IFIP91.skirt.pdf

Basically, hitting points of the cloth with the sweeping triangles of the cloth.

I particularly like this equation

P + V.t = V0 + V1.t + ((P1-P0) + (V1-V0).t).u + ((P2-P0) + (V2-V0).t).v

left is the path of the particle, right is the volume defined by the triangle.

there is an intersection if t is in the time range [0, tmax] and u > 0, v > 0 and u+v <= 1.

It does not look easy to solve. I would probably try to simplify the equation by using an approximation of the general triangle velocity, thus simplifying the volume to a sweeping triangle, and the test would fall down to a ray-triangle test, which is much easier.

There is also the problem of culling particles/areas of the cloth efficiently.

If I go with this, I'm intending to use the verlet particle system to model clothes. Simple, stable, fast. Self collisions would work simply by constraining the position of the particle to the triangle volumes.

There is also the possibility of further approximating the quads and areas in the cloth to AABoxes as a first pass.

You also don't have to test all the points. You can identify a few points in the cloth that needs to be tested, and you don't have to actually test all the points in the cloth to start with.

You can restrict points only at the outer edge of the cloth, or the corners of the cloth.

Everything is better with Metal.

What kind of cloth are you trying to do collision on? Because if it's actual clothes things can get really tricky. Mostly because animated humanoid characters often self intersect at various joints like the the back of the knee. This means doing actual physically correct self collision might not even be possible! If all you want to do is large pieces of cloth like curtains, capes and flags, it gets easier.
http://citeseer.ist.psu.edu/fuhrmann03interactive.html
http://graphics.ethz.ch/~teschner/publications/collisionDetectionComparisonWSCG2004.pdf
nice paper, the first one. bookmarked, saved and printed :)

Everything is better with Metal.

This topic is closed to new replies.

Advertisement