Thursday, June 9, 2011

Houdini Notebook #2: SOP Attributes to DOPs

You can easily use attributes that you created in SOPs in DOPs by using the point( ) or prim( ) expressions. In DOPs, the syntax is, for example:

point( $OBJID, 0, "Cd", 0)

Here I am grouping the pieces of the fractured object by primitive color:

Here I am using a Velocity Impulse Force DOP to give a sudden push in velocity at frame 30. In SOPs, I created a vector attribute called impulse.

If your attribute values change over time, you can check 'Use Deforming Geometry' in the DOP object nodes or use a SOP Solver to update the attributes every frame.