Soft Body Simulation

  

Quick guide

  • The Soft Body Simulation (New for 5) Select a prop or an accessory. You are allowed to select multiple objects to assign the same physics setting at the same time. Activate physics by clicking the Physics Settings (Shortcut: Shift + F9). Enable the Active Physics and press down on the Soft Body tab.
  • Soft body simulation is used for simulating soft deformable objects. It was designed primarily for adding secondary motion to animation, like jiggle for body parts of a moving character. It also works for simulating more general soft objects that bend, deform and react to forces like gravity and wind, or collide with other objects.
Body

Soft body simulation. Soft body simulation. WebGL not supported or not enabled. Simulation with which the robot operator interacts. The goal of the project addressed in this paper was to further develop the realness of the simulation by adding the ability to model non-rigid objects (or soft bodies). Soft body simulation is important for modeling several parts satellite-robot system, including the soft.


Navigation
  • Click+drag with the mouse to rotate, scroll to zoom.
  • Or use the buttons in the upper left. The Home button resets the view.
  • Change from Capsule to Orbit mode in the upper right to enable full 3d
  • rotation and hold Ctrl down to pan the view. (Premium users only)
Slider
  • Use the opacity slider on the left to reveal layers.
  • Click on the toggle below the slider to control layers individually.
MinecraftSelection
  • Use the searchbox at the upper right to search, or click on entities to select them.
  • Click on the background or on the X to undo selection.
  • Ctrl+click on entities to quickly hide entities. (Cmd+click on mac.)
  • Shift+click on entities or labels (or click on the 'pin' icon in a label) to pin an entity. This will keep it selected while you select more.
  • Use the visibility icon on an entities name to hide an item. Unlike Ctrl+clicking an entity the visibility tool will leave hide the items until 'Unhide All' is clicked on the upper right.
  • Use the 'Zoom to' tool on the items name to center the view on the item.
  • Use the down arrow on the items name to reveal information about the item.
  • Use the 'Pin' tool on the items name to pin an item allowing you to select multiple items.
BodyModels
  • Use the model select icon above the anatomy slider on the left to load different models.
Premium Tools
  • My Scenes allows you to load and save scenes you have created. All annotations, pins and visible items will be saved.
  • Zygote Scenes is a collection of scenes created by Zygote Media Group with annotations identifying anatomical landmarks.
  • Hierarchy is a list of all the entities you have in your current scene. You can turn parts on and off using the check marks by each object or group of objects.
  • Annotations allows you to create your own notes and markers that will be saves when you save your scene.
  • Tools:
    • Pick returns you to the default mode of picking parts and rotating your camera.
    • Slice allows you to slice the parts in your scene in either an X, Y or Z plane.
    • Explode moves all the parts in your scene away form a central point that you can interactively position.
    • Quiz when enabled when you pick a part rather than displaying the part's name a multiple choice menu will appear allowing you to quiz yourself.
Professional Tools
  • The snapshot icon at the top center will take a snapshot of your scene that can then be saved as a jpg or drawn on with the included pen tools.

This is a quick exploration of soft body simulation. I’m interested in simple, procedural methods for deforming meshes in response to their collision with other objects, specifically, character meshes made of jelly (slimes!). No animation assets are used in this project, the movement and deformation of the characters is all from the soft body simulation.

Play in Unity Editor

Simulation

Download and open this project with Unity Editor 2018.2. Then start with the simplest scene, by opening Scenes/OneSlimePrototype, and pressing play. To view the point mass locations and springs, click the Gizmos button above the Game window to make sure it is highlighted. Be aware that displaying gizmos in scenes with many soft bodies may have a noticeable effect on framerate.I’ve tested this project with Unity Editor 2018.2.15f1 on Windows 8.1.

Code Sample

Soft Body Simulation Minecraft

I have written this code as a personal project. My code can be found in the Assets/Scripts/ directory, as *.cs files (ignore *.meta files).

My Next Steps

  • Create a high performance ECS/Job system version, perhaps without using Unity’s collision system
  • Create a free form deformation shader that uses the point mass locations, or perhaps just applies shears
  • Better enforce the fixed volume of the softbody during compression, modelling a fluid like water, which typically stays close to constant volume

My Previous Steps

  • Debug the cause of NaN in the positions (this was due to too low a damping value, which led to very high velocities, and then point masses that were so far apart that their distance was represented as float.PositiveInfinity)
  • Simulate lots of soft bodies, with some variety of meshes, in a new test scene. Evaluate frame rate, and check that dimensions of soft body can be configured via the transform’s scale
  • See how many springs I can remove until the simulation destabilizes
  • Experiment with the public coefficient properties to find values that lead to numerically stable simulation, while allowing for a pleasing amount of deformation
  • Assemble point masses in a bounding box shape, and create a spring lattice, adding springs and experimenting with coefficients until the simulation doesn’t collapse over time
  • Combine pressure simulation with the mass spring system, to simulate a volume of air
  • Alter the pressure simulation to attempt to maintain constant volume, similar to a water balloon (since water doesn’t noticeably compress under typical forces).
  • Apply a nonuniform scale on a mesh associated with the soft body simulation
  • Give the soft body a periodic jump behavior, to keep things lively
  • Create a procedural animation for the build up to the jump by negating the instantaneous jump velocity (impulse) to drive the soft body into the ground, which causes it to compress and then rebound into the air
  • Clean up the prototype (MonoBehavior) code a bit
  • Write the code

Author

Soft Body Simulation Play

Chris Marchhttps://github.com/chrismarch