integrate my own GPU based cloth-simulation with bullet

guernika
Posts: 18
Joined: Fri May 07, 2010 2:20 pm

integrate my own GPU based cloth-simulation with bullet

Post by guernika »

Dear all,

I developed a particle-based GPU cloth-simulator. Mathematical model accounts for stress, shear and bending of the cloth patches, and the integrator is a vertlet integrator.
Spring force computations, numerical integration, normals computation for shading, are computed by GPU.
Here it is a video:
http://dl.dropbox.com/u/945638/table-demo_gcg.mov

However, at the moment, I have no collision detection and constraint management, hence I would like to use bullet.
I read that I can integrate collision detection with or without dynamics.
To be honest, I am oriented to the first option, but I need some suggestion before start.
I think I should derive my own new class "btCudaCloth" from btSoftBody, right?
but which methods I have to override for force computation?
If I well understand…the btSoftRigidDynamicsWorld should call some method of the btSoftBody to start force computation…am I right?

Thanks in Advance

Francesco

P.S.

If you consider, I would be glad to release my code to the bullet library.
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Re: integrate my own GPU based cloth-simulation with bullet

Post by Erwin Coumans »

We are still exploring for better ways to combine CPU and GPU work, so I dont have an answer right now, but we are looking into this. We are interested and planning to combining Bullet with GPU cloth/fluids and this should be useful for your work.
However, at the moment, I have no collision detection and constraint management, hence I would like to use bullet.
The cloth in the video doesn't penetrate the table. How do you achieve this without collision detection or constraints?

Could you open source your work using the Zlib license, and upload it to its own googlecode repository?
Thanks,
Erwin
guernika
Posts: 18
Joined: Fri May 07, 2010 2:20 pm

Re: integrate my own GPU based cloth-simulation with bullet

Post by guernika »

Hi Erwin,

the cloth does not penetrate the table because I pre-computed constraint forces.
I almost surely can open source my work, but I have to talk with my partners in my academy first.
I will give you more info next soon.

Cheers

Francesco
yaoyansi
Posts: 17
Joined: Thu Jan 01, 2009 2:14 pm

Re: integrate my own GPU based cloth-simulation with bullet

Post by yaoyansi »

wow, can't wait.