Obi Official Forum
IDea for measure fluid volume? - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Fluid (https://obi.virtualmethodstudio.com/forum/forum-3.html)
+--- Thread: IDea for measure fluid volume? (/thread-222.html)



IDea for measure fluid volume? - cyy1133 - 02-11-2017

um, sorry for my short English.. i purchased it Yesterday, but i really want to get this information hurry.
For example,
I want Measure fluid Particle volum in bowl.
Or want measure fluid Particle weight in bowl.

Is there any Api Support? or Devleop Idea?


RE: IDea for measure fluid volume? - josemendez - 02-11-2017

(02-11-2017, 05:16 PM)cyy1133 Wrote: um, sorry for my short English.. i purchased it Yesterday, but i really want to get this information hurry.
For example,
I want Measure fluid Particle volum in bowl.
Or want  measure fluid Particle weight in bowl.

Is there any Api Support? or Devleop Idea?

Just count the amount of particles inside a trigger collider, and add their masses together.
To get the volume, divide the accumulated mass by the fluid material's rest density.

You can use the collisions API to detect which particles are inside a trigger:
http://obi.virtualmethodstudio.com/tutorials/scriptingcollisions.html

cheers,