Jump to content
magneto

How to calculate curvature of a volume in VOPs?

Recommended Posts

Hi,

 

I know VDB Analysis does this but is there a way to calculate this manually in VOPs?

 

 

Merry Christmas :)

Share this post


Link to post
Share on other sites

Merry Xmas! The way I'd do this right now would be to put a point per voxel, and then check the dot product of local points sdf vector vs its own and reproject back that onto a new field... But that seems pretty inefficient, betting there's a much better way!

  • Like 1

Share this post


Link to post
Share on other sites

Thanks but I am trying to figure out how to implement the math way in VOPs practice :)

Share this post


Link to post
Share on other sites

what kind of volume?  if it's a fog volume, you can get the density gradient and then compute a dot product against a neighboring position.

Share this post


Link to post
Share on other sites

Any scalar field, because that's what Analysis SOPs support. I will try your suggestion. Is this the appropriate way to calculate curvature?

Share this post


Link to post
Share on other sites

 Is this the appropriate way to calculate curvature?

no idea at all.

Share this post


Link to post
Share on other sites

curvature computation on grid data like volumes is fairly easy. just compute the hessian and extract the curvature information you need.

 

hth.

petz

 

Just want to say thanks for that petz, exactly the information I was looking for, clear and elegantly demonstrated :-)

Share this post


Link to post
Share on other sites

I recently checked file "vol_curv.hipnc" and that's great, and I wonder if we can always output a normalized value. It would be a range mostly -1 to 1,  probably using voxel size info . I know it could be depends on polygon object and value could not reach max1 ot min-1 value.

Right now, for instance, it sets  vdbfrompolygons1>voxel 0.2, and curvature range -1 to 10. When it sets voxel size to 0.1, curvature range become -3 to 14, etc. I know, after calculating curvature, we can normalize it by fit node. But it would be great to output normalized curvature approximatly -1 to 1 in all the time, regardless voxel size. 

Thanks

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×