Softbodies clipping into each other - Printable Version +- Obi Official Forum (https://obi.virtualmethodstudio.com/forum) +-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html) +--- Forum: Obi Softbody (https://obi.virtualmethodstudio.com/forum/forum-12.html) +--- Thread: Softbodies clipping into each other (/thread-1424.html) |
Softbodies clipping into each other - JanikH - 15-10-2019 Hi, we currently evaluating if we can use this asset to approximate small bags of sand. We have had some success but are currently running into the following issue: When one of the softbodies shown below falls onto another, they "merge" together, practically getting pulled into each other. [attachment=431] Is this a problem with our setup and if so, how can we fix it? Or is this simply not a supported use case? RE: Softbodies clipping into each other - josemendez - 15-10-2019 (15-10-2019, 05:22 PM)JanikH Wrote: Hi, Hi there, Make sure their particles have different phase values. See: http://obi.virtualmethodstudio.com/tutorials/collisions.html RE: Softbodies clipping into each other - JanikH - 16-10-2019 (15-10-2019, 05:27 PM)josemendez Wrote: Hi there, Thank you very much for the quick response! I did go through the docs, but must have missed that. RE: Softbodies clipping into each other - HenryChinaski - 04-11-2019 (15-10-2019, 05:27 PM)josemendez Wrote: Hi there, What about performance considerations? Should I have as few phases as possible? And if I want to have a pile of trash bags, do I need to click on each one of them, open the particle inspector and change the phase for all particles, remember what phase was set last and check every time I have a new object, that I want to be able to collide, what the last set phase was? I would like to know if there is a specific reason, why you can't just click on a checkmark that says = "assign individual phase" and everything just works automatically? RE: Softbodies clipping into each other - josemendez - 04-11-2019 (04-11-2019, 04:14 PM)HenryChinaski Wrote: What about performance considerations? Should I have as few phases as possible? Particles with different phases generate contacts when coming close to each other. These contacts then have to be solved -as any other constraint- and that has its associated cost. Particles with the same phase basically ignore each other. Note that the number of phases you use has no performance impact whatsoever. They're simply flags that determine when to generate contact constraints. The actual amount of contacts generated as a result is what determines performance. So ideally you'd want to have everything in the same phase, and only assign different phases to these particles that need to collide with each other. Having each particle have a different phase by default would be very detrimental to performance, as every particle could potentially generate contacts with all other particles. As you can imagine this becomes very costly, very quickly. Writing a system that automatically assigns each object its own phase is kinda trivial. Check out the ball pool sample scene, as it does exactly this. It keeps track of how many balls have been spawned, and assigns a different phase to each one. RE: Softbodies clipping into each other - HenryChinaski - 05-11-2019 (04-11-2019, 05:33 PM)josemendez Wrote: Particles with different phases generate contacts when coming close to each other. These contacts then have to be solved -as any other constraint- and that has its associated cost. Particles with the same phase basically ignore each other. Note that the number of phases you use has no performance impact whatsoever. They're simply flags that determine when to generate contact constraints. The actual amount of contacts generated as a result is what determines performance. Thanks for the hint with the ball example. Exactly what I was looking for. And thanks for the explanation! |