Houdini 20.5 Solaris and Karma

Houdini Procedural: RBD

Create deformed geometry at render time.

On this page

The Houdini Procedural: RBD LOP is an alternative to the RBD Destruction LOP that gives you full control over the import process. If you still want to use the destruction node as higher level tool, you can do that. There you also have access to the procedural when you set Output Type to`Procedural. However, the new procedural is the recommended replacement for the destruction LOP’s other Output Type modes like Deforming Mesh or Dynamic Skinning.

The idea behind the procedural method is that users often had issues with bigger scenes at production scale. For example, large amounts of fractured pieces created an appropriate number of primitives - either as prototypes or individual objects. This normally lead to performance and naming problems, and the scene required (much) more disk space.

The Houdini Procedural: RBD is a separate tool that wraps up workflows from RBD/simulations and the USD side to solve the aforementioned issues. With the new tool, the USD stage remains manageable and shows only the original primitives in the Scene Graph Tree.

The following chapters illustrate how to use the new procedural in conjunction with a typical destruction scene: a tower-like construction falls down on a ground and breaks apart. The workflow scene is just an example, and you can use other objects as well.

Note

All workflows, described on this page, assume that Houdini’s Solaris desktop is active. You can find this desktop in the main menu bar’s first dropdown menu (the default desktop is Build).

SOP setups

One big advantage with the new procedural is that all SOP workflows are still the same and you set up your RBD scene in the exact same way as before.

Outputs and caching

The solver’s outputs contain the original high-resolution geometry, the constraints, a proxy version of the object and the fracture points. The last output is of particular importance: the points carry the necessary motion information from the simulation and you can use them to drive the pieces as shown in the image below. So, you only save a couple of points over the entire simulation range. This is much more resource-friendly than saving of hundreds or thousands of individual objects. To connect pieces and points in the procedural, you also need the one copy of the fractured high-resolution geometry.

  1. Add a File Cache SOP and connect its input with the first output of the RBD Material Fracture SOP. Make sure to create a separate branch for the file cache node. Rename the node to hires_cache.

  2. Turn off Time Dependent Cache to save only one copy.

  3. If necessary, adjust Base Name and Base Folder to your needs.

  4. Click Save to Disk to write the geometry to disk.

  5. Lay down another File Cache SOP. This time, connect its input with the fourth output of the RBD Bullet Solver SOP. Rename the node to points_cache

  6. Again, set name and folder if you need it.

  7. Then click Save to Disk or Save to Disk in Background to cache the simulation range to disk.

Now that you have all data on disk, you can finally add a Transform Pieces SOP to bring everything together again. Connect the output of the first file cache to the transform’s first input; the points go to the second input. The Transform Pieces SOP isn’t relevant for the procedural and only for previewing the simulation.

Nulls

In Houdini it’s very common to terminate network streams with Null SOPs. The SOP setup for the RBD procedural is no exception and here the Nulls will carry all the necessary information for the simulation.

  1. Add a Null SOP and connect its input with the output of the hires_cache File SOP. Rename the node to GEO.

  2. Lay down another Null SOP. This time connect its input with the output of the points_cache. Rename the node to PTS.

Click the image to zoom.

path attribute

Names and paths are essential in conjunction with the RBD procedural. Everything begins with a path. A path attribute controls how the geometry is partitioned into USD primitives: you’ll avoid to create one Mesh primitive per piece. The attribute will therefore improve scalability for the procedural in conjunction with large amounts of pieces. And then you also need a separate attribute to identify the pieces within those Mesh prims that contain multiple pieces.

Looping the path attribute through the RBD simulation requires several steps and here you have to be very careful: if you're missing just one step, the procedural won’t be able to connect points and pieces.

Tip

To keep track of the various attributes, open the Geometry Spreadsheet pane. You can toggle between point and primitive attributes with the and buttons.

Click the image to zoom.
  1. Add a Name SOP to your network and connect its input with the output of the last node that creates your object. Depending on your scene, this can be, for example, a basic Sphere SOP, but also a Merge SOP. If your object comes from a different network, you most probably use an Object Merge SOP, etc.

    Connect the name node’s output with the input of the first node of the RBD/fracture branch of your network, e.g. the RBD Material Fracture SOP.

  2. For the name node’s Attribute, enter path.

  3. Go to Name and enter something like /scene/tower. This path will later appear in the Solaris Scene Graph Tree. Of course, you're free to change the path according to your own requirements.

  4. Lay down an RBD Configure SOP and connect the first three inputs with the appropriate outputs of the upstream RBD Material Fracture SOP. Then link the three outputs with the first three inputs of the RBD Bullet Solver SOP.

  5. On the Attributes section, go to Transfer Attributes and append path to the already existing attributes.

  6. Add an Attribute Promote SOP and connect its input with the third output of the RBD Configure SOP. Link the output to the third input of the solver.

  7. For Original Name, again enter path.

  8. Then, open the Original Class dropdown menu. Choose Primitive to transfer the path attribute to the (simulation) points.

  9. Finally, select the RBD Bullet Solver SOP and open the Output tab. Go to Attribute Transfer and append path to the already existing attributes.

name and piecename attributes

The RBD Material Fracture SOP automatically creates a name attribute to identify the individual pieces. When you look at the Geometry Spreadsheet in Points mode, you’ll see entries like piece0-0-0, piece0-0,1 and so on.

The name and path attributes, however, are also used internally by the SOP Import LOP in Solaris, so they won’t be available as primvars (primvars is how attributes are called in USD/Solaris) on the Mesh primitives. Therefore, it’s necessary to convert name into something different. A good choice is piecename, because it’s already the procedural’s default entry.

There’s also a good reason to delete the name attribute before you export everything to Solaris: the attribute is rather heavy.

Here’s a preview of the complete SOP network followed by the workflow description for the nodes you need to create the piecename attribute.

Click the image to zoom.
  1. Add an Attribute Swap SOP. To make it a part of the GEO network branch, place it between the RBD Material Fracture SOP and the hires_cache File Cache SOP. The connection is then established automatically.

  2. Open the Method dropdown menu and choose Move. This method works like a renaming process.

  3. Set Source to name and Destination to piecename.

    On the RBD branch of the network you now need a point-based counterpart for piecename, so that pieces and points can find together in the procedural.

  4. Put down an Attribute Wrangle SOP and connect its first input with the fourth output of the solver. Link the node’s output with the input of the PTS Null SOP.

  5. For VEXpression, enter s@piecename = s@path+"/"+s@name;

    This one-liner assembles a string piecename attribute from the path and name attributes, and puts a backslash between both.

  6. Finally, add an Attribute Delete SOP and place it between the wrangle and the PTS null to connect its first input.

  7. On the Point Attributes parameter, enter name. The attribute disappears from the Geometry Spreadsheet and you can see piecename instead along with path.

Solaris setups

Now you have everything you need and you can switch to Houdini’s stage level for creating the procedural network. You’ll now also make use of the attributes you've created before. Below is the smallest possible network setup.

  1. On the stage level, create a SOP Import LOP.

  2. Next to SOP Path, click the button to open a floating operator chooser. There, navigate to the GEO null in the SOP network. File caching is optional and the import also works with “on-the-fly” simulations that are cached to your computer’s memory.

  3. The RBD Primitives field contains the content of the path attribute you've created in the SOP network. In this example it’s /scene/tower. You can also see this entry in the Scene Graph Tree and drag it from there to the parameter’s input field.

  4. Turn Piece Attribute and leave the default piecename attribute.

Points Location: Primitive

The standard choice of Points Location is Primitive. If you did not cache the simulation to disk, leave this mode.

  1. Point Primitive creates an entry in the Scene Graph Tree that will contain the simulation points from Points SOP. The entry takes name of the the SOP Import LOP ($OS) to create a path. So, with the node’s default name, the path will be /rbd_points/houdinirbdprocedural1. Change this path to your needs.

  2. Next to Points SOP you can see an Open floating operator chooser button. Click the button and use the tree menu to navigate to the PTS Null SOP. Click Accept to confirm your choice.

The Scene Graph Tree shows the Solaris hierarchy for the procedural

Points Location: File Cache

When you change Points Location to File Cache, you can see a Points Cache parameter that lets you choose a file sequence with the simulation points from disk. If your file name doesn’t match the default pattern, click the Open floating file chooser button. Use the file browser to navigate to the folder with the files, choose the sequence, and click Accept.

Preview and render

To see the result of your work, drag the timeline slider or press the Play button.

The Houdini Procedural: RBD LOP has a Preview Procedural toggle that is turned on by default. This toggle lets you display the simulation in Houdini’s viewport and render it. If you, for whatever reason, don’t want to see the transformation, you can turn it off. Then, you’ll only see the rest state.

Note

Houdini’s procedurals work with any available render delegate.

To render the simulation, you don’t have to pay attention to anything special and you can perform the render process according to your specifications.

Solaris and Karma

USD

Geometry

  • SOP Geometry I/O

    Details of how Houdini converts SOP geometry to USD, and how you can control the process.

  • Component Builder

    The Component Builder tool puts down a network snippet for creating a USD model from SOPs, with support for materials, variants, payloads, and layering.

Layout

  • Stage Manager

    How to work with the Solaris stage effectively.

  • Edit node

    Interactively transforms prims in the viewer. Can use physics collisions to position props realistically.

  • Layout node

    Provides tools for populating a scene with instanced USD assets. You can place individual components, paint/scatter components in different ways using customizable brushes, and edit existing instances.

  • Custom Layout Brushes

    How to create layout brush digital assets you can use to customize the behavior of the Layout LOP.

Look Development

  • MaterialX

    Houdini has VOP node equivalents of the MaterialX shader nodes. You can build a shader network using these nodes, or import an existing MaterialX-based shader, and use them with Karma (Houdini’s USD renderer).

  • UDIM paths

    You can encode different tiles of a texture space into different texture files, each with its own resolution. You can then specify a texture filename such as kaiju.exr, and Houdini will replace the token with the specific tile address at load time.

  • Shader translation framework

    Describes the Solaris shading framework, including shader node translation to USD primitives.

Karma User Guide

Karma basics and workflows