Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  How to optimize collisions?
#2
(15-10-2024, 06:05 PM)vrtraining Wrote: So I have turned off surface and self collisions for a cloth and also my sheet is 9x9 = 81 particles. I've tried using many techniques, the sub steps to 1-2, collision iteration is only 1. Using multiple collision layers to avoid multiple collisions. 

Hi,

With only 81 particles collision detection shouldn't be a problem - nothing should, really. Performance drops should be expected when dealing with thousands of particles if using the Burst backend, and tens of thousands if using the Compute backend.

The problem you describe sounds quite weird. Off the top of my head, only thing that could cause this is a MeshCollider with lots of small triangles in it, so that each individual particle is spawning an abnormally large amount of contacts. Maybe this is your case?

Also make sure you're not running with the jobs debugger enabled - that will heavily impact performance of all job-based code in your game.

(15-10-2024, 06:05 PM)vrtraining Wrote: Does total number of colliders in scene effect?

No, particles only consider colliding against nearby colliders.

(15-10-2024, 06:05 PM)vrtraining Wrote: But as soon as it collides with floor my frame rate drops, any way to optimize or trace it?

Use Unity's profiler. It will tell you *exactly* what the problem is. If you need help interpreting the profiling session, feel free to send it to us and we will help you make sense of the information displayed by the profiler (you can export the session using one of the buttons at the top-right corner of the profiler).


kind regards,
Reply


Messages In This Thread
How to optimize collisions? - by vrtraining - 15-10-2024, 06:05 PM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 08:11 AM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 08:38 AM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 08:49 AM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 11:06 AM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 11:51 AM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 01:26 PM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 02:00 PM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 02:13 PM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 02:43 PM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 04:09 PM
RE: How to optimize collisions? - by vrtraining - 16-10-2024, 08:51 AM
RE: How to optimize collisions? - by josemendez - 16-10-2024, 08:54 AM