CiaranM Posted April 2, 2015 Share Posted April 2, 2015 Hi, I'm using a gasfieldvop and would like to sample one of the simulation fields from an arbitrary P. The obvious way is to use the volume sample or volume sample from file VOPs. However, I'm not sure of the best way to access the desired field from the volume sample VOP. My current working solution is to dopimport the desired field into a sopnet and put a pointer to that op into sample volume from file. Works OK, but this feels pretty convoluted. So, is the a more straightforwad way to directly sample any field within gas field VOP? Thanks. Quote Link to comment Share on other sites More sharing options...
jacob clark Posted April 2, 2015 Share Posted April 2, 2015 Ciaran, You can use the Paramater VOP for this. You'll need two parameter VOPs. Both set to the same same name and type as the field you are looking to manipulate. The first parameter VOP can be used to read in the field, then set the second to 'Export Always', and this will return your output back to the sim. cheers, -j Quote Link to comment Share on other sites More sharing options...
CiaranM Posted April 2, 2015 Author Share Posted April 2, 2015 (edited) Hi, thanks for taking a look. Unfortunately, as far as I understand, using parameter or bind VOPs will return the value of the named field at the current voxel position. I'm not manipulating a field but, I'm sampling a different field at some arbitrary, far away position. Unless I'm mistaken, I should be using volume sample VOPs? At this point I don't know of a way to directly reference a DOP field in those VOPs... If I find a moment I'll throw together an example. Edited April 2, 2015 by CiaranM Quote Link to comment Share on other sites More sharing options...
tjeeds Posted April 2, 2015 Share Posted April 2, 2015 (edited) Haha, yeah this is a good one It'd be nice if the Gas Field VOP had the same Inputs tab as the Geometry DOP, that would solve this. I don't know of a straightforward way to do it as things currently stand, but you could create a temporary vector field, use one Gas Field VOP to store a noised Position in that field, use Gas Lookup to pull the values from your desired field at the displaced position and store in another temporary field, then perform any further operations in a second Gas Field VOP. But, indeed, this would be wack. gaslookup.hip Edited April 2, 2015 by tjeeds Quote Link to comment Share on other sites More sharing options...
j00ey Posted August 4, 2015 Share Posted August 4, 2015 In case anyone is looking for the answer to this, have a look at this thread - http://forums.odforce.net/topic/20023-reading-voxel-by-index-in-dops/?p=119988 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
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.