Here is a simple tutorial that shows how to implement a bubble style carpenter's level with nCloth.

3. Set the gravity to -100 on the nucleus node. This will make the bubble rise quickly. Also make the substeps 9 and the maxCollisionIterations 17 for better collision quality. The bubble will now rise, but will collapse like a plastic bag.

5. Increase drag to keep the bubble from bouncing too much. Optionally one may also wish to increase damp. If the bubble does not slide enough then you may wish to lower friction on the tube and/or bubble.

hey no more tutorials ...focus on product dev ;)
Hi Duncan!
I can’t wait to see what product developement you did! Thanks a lot for those tuts!
jocelyn “Strob” Simard, Montreal.
Thanks for taking some time to show us more neat tricks!
Can’t wait to see what the new development brings us!
Tanks a lots
I will probably will mix two methods together.
For a closeup shot i will take modeled bubbles, particles for back....
Main practical usage is for soap foam, air in the bottle, air in hydro system, biomedical purposes.
Splitting would be very difficult with this method. There might be a clever trick that could work, for example simulating many combined cloth bubbles with some kind of downstream merge history and sticky constraints, however I would be surprised if it were practical.
For splitting bubbles I would use particles. You could look at the water nCloth example on this blog and modify it to have negative gravity. That example uses nCloth with vertex collisions and no stretch to create colliding particles. This is piped into a particle system which renders the result as blobbies. A problem with using blobbies for bubbles is that they smoothy merge together, instead of packing together then suddenly merging in a pop(still a bit of a research problem). However I’ve seen pretty good bubbles using blobby rendering.



