How to apply softbody to impored mesh?

Hi everyone

I just tried apply physics to imported glb asset.
but there’s error like this.
image

It worked well on the box, but no options were applied to the asset.
If you check the log of “mesh.physicsImposter”, it’s good, but the inspector says all values are zero.
I think it’s weird :cold_sweat:

In inspector, Changing the “mass” value results in the following error:
image

How do I apply softbody to imported assets other than mesh created by mesh builder?

I really appreciate any help you can provide.

(When you press the run button, there is “b._free” error, but I think I saw it as an error only from non-wasm. It’s not my fault :sweat_smile:)

@Cedric - is that supported?

2 Issues in the playground:

  • seagulf mesh has a parent and you need to set it to null for soft body impostor
  • seagulf mesh has too many vertices (almost 15000) and ammojs encounters an out of memory error
2 Likes

I checked the contents related to soft body imposter parenting in docs.

There’s nothing I can do about the second thing you told me.

Thanks to your kind answers, I can learn a lot of information :grinning:

Kind regards,

1 Like

What’s the optimal amount of vertices for model to successfully apply a softbody simulation to it?

There is no table or appropriate numbers. It depends on your scene complexity, your target device,…
Usually, I try to keep mesh with softbody under a few thousand vertices. Like 1000 or 2000.
Most of the time, it’s for cloth or flags and runs on a desktop pc.

2 Likes