Jump to content

Surface as force volume?


Recommended Posts

Is it possible to covert a surface into a form that defines a force volume?

I have a character that will have pieces popping off it, basically a fracturing shell. I've (mostly) achieved the effect in tests with a sphere, randomly deleted glue constraints, and a metaball to provide the illusion the force is coming from under the surface itself.

While I think I can mash together metaballs to get me the form I need, it would be better if I could just use the underlying surface as the repelling force volume, especially if the character is animated/deforming.

Can this be done, either by using a surface directly as the volume or maybe as a force mask inside a larger metaball region?

Thanks!

--

mC

Link to comment
Share on other sites

you could create a velocity volume from the bounds of the surface, then use either point cloud functions to sample the N of the surface (if by "surface" you actually mean "mesh"), or if your surface is an SDF, use `volumegradient()` to get the gradient of your surface (which is sort of like the "normal" of an SDF) and bind it to your velocity volume. 

Link to comment
Share on other sites

Hey, toadstorm...thanks for the response.

Can you go into a little more detail?

Are you suggesting I create a Volume Velocity node or a Volume Velocity From Surface node to create the initial volume?

As for the point cloud functions, are you referring to something like pcfind in VEX, or a Point Cloud Iso node?

And when you refer to 'binding' to the velocity volume, are you referring to using it as a mask?

This is the first work I've done with volumes, so I'm not familiar with the approach.

--

mC

Link to comment
Share on other sites

Thanks, toadstorm; this definitely helps. More and more impressed by the VDB functionality in Houdini.

I'm still stuck on how to get the velocity to be fully recognized as a force in an RBD sim, though. With a FLIP solver it seems a bunch easier since there is an input for volumes on the solver.

In an RBD DOPnet I'm bringing in the velocity with a SOP Vector Field and wiring it through a Field Force node. I have something happening, but the Field Force node only seems to work in a single direction; there's no sense of the velocity data from the surface/VDB 'normals'.

 

volume_gradient_example_02.hiplc

Link to comment
Share on other sites

The Field Force DOP, confusingly enough, doesn't want a field; it wants geometry. You attach a SOP Geometry DOP to the green input, and provide a point attribute (defaults to "force") to create the force field from, and then it makes the field for you. You could just create point normals on your original geo before the shatter and rename the attribute to "force" and you'd be good to go.

Since Packed RBDs are also points as far as Houdini is concerned, you can use POP DOPs on them in place of traditional DOP forces (which can be confusing, clearly). I converted the velocity VDB to standard Houdini volumes, then used POP Advect By Volumes to apply the volume as a force (i.e. not wind). 

volume_gradient_example_03.hiplc

Link to comment
Share on other sites

Great example, Henry. I think I'm all set on the VDB approach. And it looks like I can use the approach on either static or deforming geo, which is fantastic.

I'm curious about the the Field Force example you gave. I gave it a go based on your description but can't seem to make it work. I've tried referencing both the shatter geo and the interior geo in the SOP Geometry node, but in both cases the force attribute isn't coming in with the geo.

Does this approach also require a SOP Solver node to wire up the points and forces?

Metaball_Test_03a_FieldForce.hiplc

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...