Jump to content

Masking a force in DOP using a SOP attribute (After a FLIP solve)


luithne

Recommended Posts

Hi guys,

I've been looking into Houdini recently, specifically the FLIP solver. I was wondering if anyone had any thoughts on a workflow for taking an attribute created in a SOP and using it to mask a force.

In this case there is a sphere which has particles spawned in the volume, the sphere has two groups made from it which are then converted to attributes. These are colourised red/green in the example image.

What I want to do now is use that attribute in DOPs to mask a force so that, for example, a gravity would only affect the red particles. This is after it has gone through the FLIP solver. I know the data is there as I can see it under flipobject\geometry, and I have also used a dopimport in a SOP solver and been able to access those attributes there. I'm just not sure how to access it in the DOP.

I know there was a Peter Quint video demonstrating using a poppoint expression in a POP solver to group an attribute, but as far as I know this limits the forces you can use to the pop forces. Also I'm not sure how this would now be applied to Houdini 13's updated POP solver.

I was also reading about a point/prim expression in a DOPs group node, but i couldn't figure that out either, and wasn't sure if it was actually finding the attribute.

If anyone has some insights they would be greatly appreciated

Thanks

post-9849-0-01122100-1383833821_thumb.jp

Link to comment
Share on other sites

So I was doing some testing with this and I have found that if I import two spheres into a rigid body solver and they have a unique attribute assigned to them, I can group them using the point() expression and then have forces masked by these groups. However if I apply the same concept to a FLIP solver, it does not work. Is this even possible with the FLIP solver or do I need to modify/use a different expression

I have attached two example scenes; one of the working rigid body setup and one of the FLIP setup which does not work.

Group_RBD_Theory_02.hip

Group_FLIP_Theory_03.hip

Link to comment
Share on other sites

To my knowledge the group DOP only create groups out of simulation objects.

Pre H13 I used to build my own forces with sop-solvers and/or microsolvers when I needed something masked.

In H13 you got a bigger range of tools out of the box with the new POP Forces.

You can put a maskfield in the second plug of the DOP forces, however I usually find that abit hard to controll and slow.

What kind of forces are you looking for?

EDIT...

Attaching file with POP forces masked by groups via VEX expression.

Keep in mind that flip is solving the velocity on a grid. You are not going to get a perfect per particle mask when red and green particles share voxels.

Group_FLIP_Theory_03.hip

Edited by mawi
Link to comment
Share on other sites

Thanks a lot guys, I've just checked through the files. So I am guessing POP forces are the way forward.

As for what I'm looking at doing, I'm not after anything in particular, but just learning how I could manipulate FLIP (I am a 3dsmax user, looking into Houdini primarily for the fluid simulation but with a view to expand into other dynamic work)

I work in medical animation, so I would be interested in doing very abstract and controlled fluids. We often do things like cell division, cell apoptosis (cell dissolve/death), absorption of molecules etc. In this example I was going to see how the FLIP solver would react if i had a sphere of fluid and the two halves were affected by different forces, pulling the fluid apart into two pieces.

I had done a test having two spheres of fluid be attracted by a POP attract (setup in H12) which looked really nice, so I was looking for the reverse affect.

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