Jump to content

Field data


Macha

Recommended Posts

How is data from fields in dops stored in volumes?

We can read pressure, velocity and such things from fluid calculations into SOP context. I was thinking of using an attribute transfer to blend those values with geometry but I can't figure out how they are stored in the volume data, and how to extract them.

Link to comment
Share on other sites

Yeah, the fastest way is usually using VolumeSample from within a VOP SOP to read the values into point attributes. The points will go into the first input, the volumes in the second, then on the VolumeSample VOP change the OP Input Index to 1 and the Primitive Number to whichever volume you're interested in.

If you want AttribTransfer style filtering, the easiest way might be to create a grid of points that correspond to each voxel (Box SOP should do it with some expressions). Then VolumeSample your values from the fields to the grid points, then AttributeTransfer to your geometry. If you don't care about filtering, i.e. you just want point sampling, you can VolumeSample straight to your geometry.

Link to comment
Share on other sites

I don't believe you can sample SIM_SDF nor SIM_ScalarFields geometry data :(

I think you can only sample SIM_Geometry. This is an outstanding RFE: 35603, logged in May, 2009.

echo `volumevoxeldiameter("/obj/AutoDopNetwork:obj0/density",0)`

Are these tools capable of querying dopnets?

Thanks,

Jason

2009-05-21 11:49:32 (EDT): jlait:

Not if it isn't a SIM_Geometry.

note that volumevoxeldiameter("/obj/AutoDopNetwork:obj0/density/Visualization",0) hopefully does work.

2009-05-21 14:42:18 (EDT): jiversen@rhythm.com:

Ah, thanks. Would it make sense to extend the volume*() functions to be able to be able to access SIM_ScalarField and SIM_SDF, etc?

2009-05-21 15:00:39 (EDT): jlait:

Yes it would. Which is why this RFE remains.

Link to comment
Share on other sites

Cool. Thanks for helping me out there. Now I'm getting a grip on this stuff.

Attached image shows a velocity field transferred onto points and copy-stamped spheres.

post-4013-126751538218_thumb.jpg

Edited by Macha
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...