Home » Featured, Houdini

Houdini: Multiparms

25 August 2009 28,431 views 5 Comments

If you’ve never heard of multiparms; here are a couple of examples I’m sure you will know:

AddSOPObjectMergeSOP

The Add SOP on the left uses a multiparm to get a list of point positions from the user, while the Object Merge SOP shown on the right uses a multiparm to merge geometry from multiple sources at once.

This simple tutorial will show you how to use multiparms in expressions and your own tools.

Introduction

Multiparms are Houdini’s way of getting a list of items from the user. They comprise of a single parameter that stores the number of entries in the list, and a list of parameters numbered sequentially that make up those entries.

multiparmexplained

Something which is particularly useful is that each entry doesn’t have to be made up of just one parameter. Houdini lets you store multiple parameters in each entry. In effect, you can think of each one being like a record in a database. Each one can contain a number of fields in which you can store information.

In this tutorial, I’ll only be looking at a multiparm that contains single parameter entries.

Initial Setup

Step 1To start, make a Geometry object, call it “geo_boxes”, and press Enter to jump inside.

Step 2Inside, create a Box SOP, and a Copy Sop with their default parameters, and connect them as shown.

Sticking to the Houdini convention that most people use; add a Null Sop called “OUT” and set its display flag.

On the next page, we’ll create the multiparm.

1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 5.00 out of 5)
Loading...

5 Comments »

  • varomix said:

    Thank you Andy, that those look very useful
    great tutorial

    thank you

  • AndyN (author) said:

    Great. Hope it’s of some use.

    Yep, I’m trying to knock these tutorials out whenever I bump into these useful little nuggets of information. These little discoveries happen quite frequently when I’m using it in production, so hopefully there’ll be more soon.

    Cheers!

    Andy

  • rob east said:

    Great breakdown Andy !. Glad I stumbled onto your blog

  • erwin said:

    Is it possible to retrieve the currently selected tab number, when using a multiparm (tab) folder instead of a multiparm (list) folder.

    When I use a ch(“”) expression, it retrieves the current amount of folders, but not the selected folder like when a group of radio button folders is used.

  • AndyN (author) said:

    Good question. I don’t know off the top of my head. I’d have to have a dig around and do a few tests (which by the sound of it, you’ve already done). If I find out, I’ll post back here.

    Cheers,
    Andy

Leave your response!

Add your comment below, or trackback from your own site. You can also subscribe to these comments via RSS.

You can use these tags:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This is a Gravatar-enabled weblog. To get your own globally-recognized-avatar, please register at Gravatar.