2D soft-body physics engines?

  • 2D soft-body physics engines? Griffin

    Hi so i've recently learned the SFML graphics library and would like to use or make a non-rigid body 2D physics system to use with it. I have three questions:

    The definition of rigid body in Box2d is

    A chunk of matter that is so strong that the distance between any two bits of matter on the chunk is completely constant.

    And this is exactly what i don't want as i would like to make elastic, deformable, breakable, and re-connection bodies. 1. Are there any simple 2D physics engines, but with these kinds of characteristics out there? preferably free or opensource?

    2. If not could i use box2d and work off of it to create it even if it's based on rigid bodies?

    3. Finally, if there is a simple physics engine like this, should i go through with the proccess of creating a new one anyway, simply for experience and to enhance physics math knowledge? I feel like it would help if i ever wanted to modify the code of an existing engine, or create a game with really unique physics.


  • The term you are looking for is soft-body physics.

    Wikipedia has a nice list. They're all 3D AFAICS, but should be good.

    Also check out this SO question.

    A great book (it's rigid body, but all the maths and physics are there; it's also 3D, but is trivial to transfer to 2D) is Game Physics Engine Development. It implements a particle based system before moving onto rigid bodies and collision.

  • You can use rigid body systems to create soft body and fluid dynamics. Physical reason behind it? Well, essentially, atoms are small rigid bodies. This isn't completely true of course, but for simplicity you can view them as such. And soft bodies are obviously made from atoms.

    So, how do you create "soft bodies" using a rigid body engine like Box2D?

    The essential technique is to bind points in your body together using joints. For example, if you connect the ends of a list of lines together using distance joints (meaning the distance between two joints must be constant), it will roughly behave like a piece of cloth.

    But that's just a rough description. A lot of "elementary field work" with Box2D has been done by ewjordan, one of the developers of the Java-port of Box2D. Here's a good starting point: http://www.box2d.org/forum/viewtopic.php?f=8&t=1978

c++ physics
Related questions and answers
  • examples/sites that could give me the specifics needed to actually make this such as equations and required physics knowledge. It would be great if anyone out there also would give me their attempts or ideas. finally I was wondering if it was possible to... use the source code of an existing 3D engine such as Bullet and transform it to be 2D based? use the source code of a 2D Rigid body physics...hey so I've decided to Code my own 2D soft-body physics engine in C++ since apparently none exist and I'm starting only with a general idea/understanding on how physics work and could be simulated

  • Choosing an Audio API Aidan Knight

    library and stick with it. I switched physics engines 3 times which caused quite a bit of wasted time, so I would like to be set when I pick an Audio lib. I will be falling into the "indie" section as far as licensing goes. Here is what I have so far.. FMOD - Quality Middleware, success has gone to their heads and it seems they did away with the indie license recently. Price range seems to go from Free - 3000$ - 6000$ which pretty much excludes this. BASS - So far this is what I am leaning towards. Simple API, great feature list, and quite a bit more. The pricing structure looks somewhat similar

  • *) (node)); // Add it to the physics world World->addRigidBody(RigidBody); Objects.push_back(RigidBody); m_pNumEntities++; // End Physics } I then have a method to create a cube and give it rigid body physics properties. I know there will be errors here as I get the items colliding with the ground but not with each other properly. So I would appreciate some input on what I am doing wrong. void...); // CReate the rigid body object btRigidBody *RigidBody = new btRigidBody(TMass, MotionState, Shape, LocalInertia); // Store a pointer to the Ogre Node so we can update it later RigidBody->

  • i'm wondering if there's any 2D AI source code or engines out there. I'm inspired by the Euphoria engine, and want to use whatever is already out there to make something like it in 2D, where the characters can move left and right, and attempt to preserve themselves. The only new feature i would want to add on is ability to learn from common results after an action. I'm thinking the way it would... to AI would probablly be helpful as i've never worked with it: How do you guys suggest i get started? (Btw: i'm using box2D/ SFML at the moment) oh yeah and preferably open source =)

  • that.... Allows easy setup of controls for a game Makes events like clicking and holding on an object easy to setup, as so objects can be dragged around afterward Are there any simple libraries...Sorry for the ackward title, but i don't know what to call it exactly. I'm looking for code or libraries that allow easy creation of commonly used user input devices, and code/libs that make gaming controls easy to set up (i'm using SFML and Box2D at the moment) I don't want to re-invent things like buttons, arrows being placed wherever the mouse is located, and more game specific items

  • There isn't much more to the question. I'm not concerned about overhead, as I'm sure they are both fine for my purposes. Basically, I am familiar with Box2D concepts because of the Farseer Physics Engine, but I want to use Bullet when I make the jump to 3D stuff. Perhaps Bullet has some educational value for me even in the 2D realm? The generalized version of the question is: should I use a 3D physics engine for a 2D game if I plan to utilize a 3D physics engine in the future? Or is this a waste of time which would not provide educational value?

  • better. I would also like compatability, If Theres one that fits DirectX(at least 9) and OpenGL, then that would be good) 2D Graphics(I liked SFML, so it its possible to get something that works with SFML... with the Physics correctly... So my main question is: What would be a good combination of libraries to make an online game with? Im sure that many people have good combinations of libraries for making a game...) Also if there are any other libraries that work well with these I would like to know. Any answers would be very helpful. and details would be even nicer =) Thanks in advance. -Molma

  • the world for a few seconds ahead. It looks like I can make a parallel world the "long way" - for each body in the world, copy the body data back into a def and re-create it, then copy the fixtures... (and if so, was it actually a workable design or not?), or if Box2D has some affordance for doing this within its API which I am missing. ...I'm working on a platformer where I'd like to be able to move or copy bodies between multiple Box2D b2Worlds. The desire has cropped up three times now - moving objects between documents in my editor

  • Possible Duplicate: Are there existing FOSS component-based frameworks? What open source game engines with component-based design of game objects do you know? And which best of them? I mean best not in Graphics or Physics, but best in context of Behaviour, Messaging, etc. This question is the result of inspiration by another question Thank you!!!

Data information