Jump to content
StRaToX

Gas Match Field (with field from different objects)

Recommended Posts

StRaToX    2

Hi I'm new to Houdini and recently I've been getting into DOPs.

I have a question

I've been trying different things out in dops to see how they work,

been playing around with the "Gas Match Field" node and found that it works quite nicely when both fields you are supplying the node with are from the same object

Like on picture 1, both the "myField" field and the "heat" field are part of the same object and the node works just fine

But what I can't figure out is how to make the node work when I'm supplying it with fields from different objects. On picture 2 "myField" is part of an empty object and the "heat" field is part of the smoke object, I tried to reference them 

via their paths like on the picture 2 but unfortunately it doesn't seem to work.

 

Does anyone have any insight into why this may be, 

I can see how referencing field from different objects can come in handy not just for this scenario.

Picture_1.png

Picture_2.png

Share this post


Link to post
Share on other sites
Skybar    247

Gas Match Field DOP creates a new field. "Field" is the name of the new field, and "Reference Field" is the field it should take it's dimensions from. So you dont have to create the new field beforehand because that is what it already does. Keep in mind that this only creates a new, empty field. You have to separately copy/add data to it afterwards.

  • Like 1

Share this post


Link to post
Share on other sites
StRaToX    2

Thanks for replying, really appreciate it

So your saying that even thought the description for the field parameter says :
"The name of a field that one wants to create. If it doesn’t exist, one will be created. This can be a space separated list of fields to create many fields in one DOP." , instead it only just makes field and doesn't modify them.

Ok then. But in that case how would I go about matching an existing field to another
And also I really have to know, on the second picture am I even referencing these field the right way, I mean the path to them and all that 

  • Like 1

Share this post


Link to post
Share on other sites
Skybar    247

Actually no, sorry, you are right. It does match the Reference Field if the field already exists. Sorry for confusing you :). Not sure if it is possible to match a field from another object like that, but someone else might know.

Share this post


Link to post
Share on other sites
Dam    5

Hi Josh, have a look a this hip example, I prepared it for this post initially,

But maybe can be helpful also for your case. feel free to send your hip file too so I can have look at it. Cheers - Dam 

Flip_TurbulenceSopScalField.hipnc

Edited by Dam

Share this post


Link to post
Share on other sites
StRaToX    2

Why is it that after you used the gas match field node which creates the non-existent "mask" field there's a wrangle ode which does the same ?

Also do merge nodes run their child nodes in order from left to right ? 

This next question is unrelated but how do I copy or transfer a field or data from one object to another ?

Share this post


Link to post
Share on other sites
Dam    5

There is a wrangle "f@mask=@density" because the gas match field creates an ampity field with same size and res of density field and name "mask", but since this field it's empty yet the wrangle fills the field with the density data, my bad I should have named the wrangle fillMask. Not sure to understand the other two, do you have a specific example or simple hip? Cheers

Edited by Dam

Share this post


Link to post
Share on other sites
StRaToX    2

Alright I get it now,
thank you everyone.

Regarding the merge node question

I was thinking about when you want to perform actions in an order does the merge node provide that, as in nodes connected to it execute in order from the first to last 

 

Share this post


Link to post
Share on other sites
Dam    5

For micro solvers the computation order it s from left to right, after the solver generally it depends to the merge relationship.

Edited by Dam

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

×