Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How easy it is to modify the softbody mesh during runtime?
#1
Lets say I have two cubes A and B, and I want to cut both A and B in half (the cutting plane is not pre-determined but is based on user input), then join half of A and half of B together.

What is the best approach to this kind of scenario?
Reply
#2
(03-11-2021, 07:27 PM)snowtv Wrote: Lets say I have two cubes A and B, and I want to cut both A and B in half (the cutting plane is not pre-determined but is based on user input), then join half of A and half of B together.

What is the best approach to this kind of scenario?

Not trivial at all. Cutting/tearing softbodies is hard, so much that it's still a very active academic research field. Roughly, you could do it this way:

- Determine which triangles in the mesh intersect the cutting plane.
- Reorganize mesh topology around these triangles (generate new vertices, new triangles, etc), while keeping correct texture coordinates, colors, normals, etc.
- Reorganize softbody constraints around the cut: disconnect particles at different sides of the plane, reseed new triangles with particles and create new particles and shape matching clusters where needed. Then, re-bind each chunk to the particles.

Unless you're comfortable with math/physics and C# coding, it's not easy, specially in a particle-based engine. Continuum methods like tetrahedral FEM generally make it easier to do this.
Reply
#3
(04-11-2021, 08:35 AM)josemendez Wrote: Not trivial at all. Cutting/tearing softbodies is hard, so much that it's still a very active academic research field. Roughly, you could do it this way:

- Determine which triangles in the mesh intersect the cutting plane.
- Reorganize mesh topology around these triangles (generate new vertices, new triangles, etc), while keeping correct texture coordinates, colors, normals, etc.
- Reorganize softbody constraints around the cut: disconnect particles at different sides of the plane, reseed new triangles with particles and create new particles and shape matching clusters where needed. Then, re-bind each chunk to the particles.

Unless you're comfortable with math/physics and C# coding, it's not easy, specially in a particle-based engine. Continuum methods like tetrahedral FEM generally make it easier to do this.

So let's say my mesh is pretty high-poly and I don't need to do the generation of new vertices and triangles (I guess I may have to duplicate some vertices and triangles along the cutting plane), what is the best approach with Obi to modify the topology of existing softbody and form new softbody?

Since in my scenario, the cuttings won't be too random, my current plan is to just pre-cut the mesh a few times, and using constrains to sew them together at first, then break them apart based on user input, and create new constrains to sew them back to form the new topology.
Reply