Difference between revisions of "Mesh/Decomposing a mesh for physics shape"

From Second Life Wiki
Jump to navigation Jump to search
m
Line 1: Line 1:
__NOTOC__
[[Image:MeshWalkthrough-Decomposing Physics-Splash.png|300px]]
* Now we're going to make the physical shape that can be bumped into. The model that you see and the model that you bump into can be defined by different meshes. If the physical shape is extremely detailed, the simulator will slow down when the model collides with objects or avatars. We're ideally looking to make a physical shape that is only detailed enough to give the illusion that you are bumping into the shape that you see.
* Now we're going to make the physical shape that can be bumped into. The model that you see and the model that you bump into can be defined by different meshes. If the physical shape is extremely detailed, the simulator will slow down when the model collides with objects or avatars. We're ideally looking to make a physical shape that is only detailed enough to give the illusion that you are bumping into the shape that you see.
* Download duck.dae from
* Download duck.dae from

Revision as of 12:13, 8 October 2010


MeshWalkthrough-Decomposing Physics-Splash.png

  • Now we're going to make the physical shape that can be bumped into. The model that you see and the model that you bump into can be defined by different meshes. If the physical shape is extremely detailed, the simulator will slow down when the model collides with objects or avatars. We're ideally looking to make a physical shape that is only detailed enough to give the illusion that you are bumping into the shape that you see.
  • Download duck.dae from

https://collada.org/owl/download.php?sess=0&parent=126&expand=1&order=name&curview=0&binary=1&id=698

  • Open the Build menu, choose Upload, click 'Model...'
    • Alternately, open the Inventory, click the + menu button and Upload > "Model"
  • A file dialog box will open
  • Pick the COLLADA file you downloaded from your computer.
  • The Import Model window will appear.

Mesh upload model.png

  • Click the 'Generate LOD' button at the top of this window.
  • The viewer will take a few seconds to process this
  • Click the drop down next to Physical Shape, choose Triangle Limit.
  • Type 500 into the text field and hit Enter (You can choose a different number. 500 still makes a good approximation of the duck shape. Using a very large number will cause the next steps to take longer to process)
  • The duck will appear in the preview window

MeshWalkthrough-Generate LOD and set Physical Shape.png

  • Click the >> button next to Physical Shape to open the Physics

Decomposition tool window.

  • In the Physics Decomposition tool window set Decompose Quality = Normal
  • Set Method = Surface

MeshWalkthrough-Physics Decomposition window.png

  • Click the Decompose button.

MeshWalkthrough-Decompose.png

  • The viewer will take a few seconds to process
  • Slide the Explode slider to see the Decomposed shape. (The explode slider does not change the Decomposed shape, it only moves it away from the Mesh visually so you can see it clearly.)

MeshWalkthrough-Explode view.png

  • Slide the Detail Scale to 0.075
  • Set Simplify Method = Detail
  • Click Simplify
  • The Decomposed pieces are simplified into a few objects.

MeshWalkthrough-Simplify.png

  • Click the Upload button to upload the mesh with this simplified Physics Shape.
  • Rez the Model
  • Enable the Develop menu with ctrl-alt-q
  • Enable Develop menu > Render Metadata > Physics Shapes

MeshWalkthrough-Physics Shapes setting.png

  • Objects will display a color overlay. A blue overlay indicates the

object's physics are efficient and will produce very little load on the sim. A red overlay indicates the object could potentially cause high physics lag on the region.

MeshWalkthrough-Physics Shape efficiency visualized.png