Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Skinned Cloth with Proxy
#11
(26-07-2021, 08:41 AM)josemendez Wrote: Hi,

Make sure you're not using skinned cloth for both slave and master, as this it's currently unsupported as explained in this thread. Let me know otherwise so that I can take a look at your use case.

kind regards,

Thank you! I was able to solve the issue, my high res mesh was not marked as read/write, now the mesh/cloth simulation works for highres/proxy.
I wonder if there is a way to check that in a future product update, to help warn users.

But FPS is quite low (20fps), hmm not sure how to fix that, yet. Any tips would be welcomed.
Reply
#12
Hi there,

Code:
Thank you! I was able to solve the issue, my high res mesh was not marked as read/write, now the mesh/cloth simulation works for highres/proxy.
I wonder if there is a way to check that in a future product update, to help warn users.

Unity already checks if any code is accessing a non-readable mesh and throws an error to the console to warn you about this. In the future we might place a warning in the inspector UI directly, just like we do with blueprints.


Code:
But FPS is quite low (20fps), hmm not sure how to fix that, yet. Any tips would be welcomed.

There's lot of possible reasons for performance issues. Best advice I can give is take a look at the profiler (specially if you're using the Burst backend). This will give you detailed information about what is time being spent on.

Tweaking constraint iterations and substeps is a good place to start, as these largely define the quality/performance ratio of the simulation.

Iterations can be adjusted on a per-solver basis:
http://obi.virtualmethodstudio.com/manua...olver.html

And substeps are adjusted on a per-updater basis:
http://obi.virtualmethodstudio.com/manua...aters.html

The manual contains an in-depth explanation of how the engine works and how iterations/substeps affect it: http://obi.virtualmethodstudio.com/manua...gence.html

A quite common reason for bad performance in any physics engine (including Obi) is death spiraling. This happens when the physics loop can't keep up with rendering, and Unity updates physics multiple times per frame. Check if FixedUpdate() is being called more than once per frame (the profiler will tell you this), then increase your timestep if necessary.

kind regards,
Reply