Real Time Cloth Simulation on iOS

Post Reply
cosmin.pahomi
Posts: 1
Joined: Tue Mar 25, 2014 10:54 am

Real Time Cloth Simulation on iOS

Post by cosmin.pahomi »

HI,

I'm new to the 3d physics world and I have some questions about the Bullet engine.

It's there a possibility to implement a real time cloth simulation an iPad without affecting the performance of the app?
I've already integrated the Bullet physics into my Cocos3d app, and I've done some tests with rigid bodies and soft bodies (with a bouncing ball with ~2000 vertices).
Everything is smooth when I'm using rigid bodies, but when I switch to the soft bodies, my frame rate drops at 7 on the latest iPad (air).
It is possible to improve the performance or should I take another approach?

I was thinking to simulate the cloth animations in the background and when is finished to display it. But I'm not sure how what impact will it have on the app because I will use some models with at least 50000 vertices each and from what I'm seeing I will have to wait a long time for a 5 seconds animation.

Is there a better approach to this problem?

Thanks
Basroil
Posts: 463
Joined: Fri Nov 30, 2012 4:50 am

Re: Real Time Cloth Simulation on iOS

Post by Basroil »

You do understand that even the fastest ipad is still powered by a chip slower than what you had in mainstream computers back in 2003 right? If you want to see how it'll work on an ipad, run the simulation on your computer, and multiply the time by 100 to get a very rough estimate. High vertex cloth is hard enough to do on desktop equipment, I doubt it's practical in portable devices without using GPU offloading.

You might be interested in making reduced mesh approaches though, http://www.seas.upenn.edu/~ladislav/pap ... -sig11.pdf uses precomputed harmonics to upscale using distortion of a coarse mesh. Claims about 30x speed improvement for estimation of 10k vertices using a 100 point coarse mesh, at the cost of some accuracy. Worth looking into if you need realtime cloth in low power systems.
Post Reply