User guide
94
Macros
Macros are nodes that wrap any single node, or group of nodes, and publish them so that their state is saved and
they can be recalled in other projects. Macros wrap functionality, allowing you to hide logic, or group logic that you
can then reuse multiple times. For an introduction to macros, and their uses, see the Groups and Macros >
Introduction to Macros chapter in the Katana User Guide.
You can create a macro from any node by using the wrench menu at the top of the node’s Parameters tab, and
choosing Save As Macro... although Macros are more typically - and more usefully - made from groups. You save a
macro from a Group node in the same way you would from any other node (by choosing Save As Macro... from
the wrench menu in a group’s Parameters tab).
By default - if no other directory options are set - macros are saved into the Home directory in .katana/Macros/_
User and are given the suffix _User.
You can also read macros from other directories included in your $KATANA_RESOURCES environment variable.
Macros are picked up from sub-directories called Macros and take the name of the parent directory as suffix. For
example, if you point your $KATANA_RESOURCES to /production/katana_stuff/_studio you can put macros in
/production/katana_stuff/studio/Macros and they will automatically be suffixed with _studio.
Once exported, you add a macro to a project in the same way you would any other node, such as choosing it from
the Tab hotkey node creation menu.
Adding User Parameters
You can add user parameters to any node, but they’re particularly useful in groups and macros, where user
parameters on the parent node can drive parameters on child nodes, or even on nodes in the recipe outside of the
group or macro.
The example in the Groups and Macros > Introduction to Groups > User Parameters section of the Katana User
Guide links the type of a PrimitiveCreate node inside a group, to the value of a user parameter on the parent. While
13 GROUPS, MACROS, AND SUPER TOOLS | MACROS