dfki-ric / phobos

An add-on for Blender allowing to create URDF, SDF and SMURF robot models in a WYSIWYG environment.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

"Create Inertials" fails if not all vertices are selected

kevinfoley opened this issue · comments

Summary: The "Create Inertials" operation fails unless all of the vertices in a visual geometry object are selected.

Steps to Reproduce:

  1. Open the attached Blend file.
  2. Select the Base object (the cube centered at 0,0,0)
  3. Press Tab to enter Edit mode
  4. Press the A key until no vertices are selected
  5. Press Tab to exit Edit mode
  6. Click "Create Inertials"
  7. Observe that Phobos displays a divide-by-zero error
  8. Press Tab to enter Edit mode
  9. Select some, but not all, of the vertices
  10. Press Tab to exit Edit mode
  11. Click "Create Inertials"
  12. Observe that Phobos displays an error "operands could not be broadcast together with shapes"

Expected result: The Create Inertials operation succeeds regardless of which vertices are selected in the mesh.
Actual result: See steps 7 and 12 above.

Workaround:

  1. Press Tab to enter Edit mode
  2. Press the A key until all vertices are selected
  3. Press Tab to exit Edit mode
  4. Click "Create Inertials"

Environment:

  • Windows 10 Pro 64-bit
  • Blender 3.3.15 (LTS)
  • Phobos 2.0.0

@kevinfoley Interesting find thank you. I could not reproduce step 7. Please take a look at my commit and see if it fixes it anyway

@AlpenAalAlex Your fix appears to work. Thanks!