Jump to content

FLIP, VDB and Collisions


Whatsinaname

Recommended Posts

I'm getting nuts with a scene where water is flowing through some tubular/ pipe geometry. It is no problem creating a VDB out of the original geo, without any holes just the way I want it to be interpreted by the solver.

 

However, no matter what I do, when I simulate using that geometry, the solver doesn't get it. Visualizing Collisions in my flipobject node, my tube looks more like a skeleton than anything else. I tried setting up collisions in two different ways:

 

1. static objects

 

I set the SOP path to my VDB, in Collisions I changed the mode to Volume Sample and set my VDB as proxy volume. As far as I understand the system, it should use the Proxy Volume as collision volume. But it doesn't...all I get is the "skeleton" and no working collisions.

 

Then, inside the static object node, I ticked on Collision Guide Geometry, set it up to be a smooth collision object and wrote that to disk using File/ File mode. I made sure it is set to Read or at least Automatic...simulate (resetting my DOP net)...and there is my skeleton again and all the water running through.

 

Everything I see in Show Collision Guide Geometry seems to have nothing to do with the object taht the solver calculated for collisions in the end.

 

2. Volume Collisions.

 

Inside DOPs, I create a sourcevolume node, set it to collision and set the Volume Path to my VDB (and scale source volume to -1). On my VDB, I changed the name of the SDF intpo collision, and created an attribute collisionvel set to point.v (which I initialised with the normal in a VOPSOP)

 

...which is getting me the same skeleton and leaking as with the static objects.

 

Does anybody have an idea what might be going wrong, here? Or what else I could try to make my collsion Volume work?

Edited by Phlok
Link to comment
Share on other sites

Thank you very much. I didn't notice the collision field resolution is taken into account when setting a Proxy Volume. I think this is something that should not be, as I feed in a Volume (the proxy volume), so why doesn't Houdini just use this Volume, but will create a new volume out of that, instead?

 

This doesn't feel very efficient to me.

Link to comment
Share on other sites

Thank you very much. I didn't notice the collision field resolution is taken into account when setting a Proxy Volume. I think this is something that should not be, as I feed in a Volume (the proxy volume), so why doesn't Houdini just use this Volume, but will create a new volume out of that, instead?

 

 

For starters, the point of a sparse VDB SDF is that it is not defined in the whole volume, just in voxels near the surfaces. The simulation on the other hand is calculated in every voxel of the volume, and needs to work on dense volumes (values defined in every voxel). Simulating on sparse volumes (not just collision, but other fields as well) is a hard problem, I think it has been done somewhere so I guess it is possible, but at least with the current Houdini simulation framework it is not doable. Hopefully at some point in the future :)

 

In practice, even dense collision volumes are resampled into the simulation grid in Houdini FLIPs, which might sound like extra work at first. You could think of it as a programming optimization deal. When the simulation is run, you need to sample the collisions at simulation voxels in several stages of the sim. I guess you could sample the original collision surface every time, but precalculating the collision volume once and reusing the already resampled surface is most probably a good tradeoff.

Edited by eetu
  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...