On this page | |
Since | 19.0 |
This node allows for more destructive editing of the scene graph, in ways USD workflows normally discourage. When the layer stack is flattened into a single layer, this node can rename, remove, and reparent primitives and variants however. Hence the reason this node flattens the Layer Stack. However this will not allow you to rename primitives behind references or payloads.
Tips
-
See the help for the Operation parm below to see what kinds of edits the node can perform.
-
You can perform some of these operations interactively using the
Stage Manager, however using this node lets you select the prims using patterns.
-
You can use this node within a For Each block, unlike the Stage Manager.
-
This node is a wrapper for USD’s
SdfCopySpec
andSdf.BatchNamespaceEdit
APIs.
Parameters
Flatten Node Input Layers
Automatically flatten all incoming sublayers. If this is off, you can only edit the selected prims within a single sublayer. If you want to edit prims across sublayers, you must turn on Flatten node input layers to flatten the incoming sublayers into a flat stage before the node moves the prims.
Primitives
A space-separated list of prim paths to modify. This can include primitve pattern matching syntax, which allows advanced matching based on various criteria.
Operation
How this node should edit the prims selected in the Primitives parm above.
Reparent Primitives
Moves the selected prims to be children of the New Parent Prim.
Rename Primitives
Renames the selected prims. Uses the Old Name token and replaces any occurrences with New Name.
Remove Primitives
Removes the selected prims.
Rename Variant Set
Changes the name of a variant set on the selected prim(s).
Remove Variant Set
Removes a named variant set from the selected prim(s).
Remove References
Removes reference, payload, inherits, and/or specializes arcs from the selected prim(s).
New Parent Prim
When Operation is Reparent primitives, use this prim as a new, least local transform. By default creates missing primitives as over, but options exist to define new parent prims.
Create Parent Prims
Whether to create new intermediate prims when the New Parent Prim path does not already exist.
Primitive Type
If any parents of a path in Primitive paths do not exist, this node will automatically create them. In this case, it will create parent nodes of this type.
Primitive Specifier
Only Define Missing Prims
When Create parent prims and this parameter are on, the node authors overrides on existing prims instead of redefining them in this layer. When Create parent prims is on but this is off, the node redefines all the parent prims even if they already exist in another layer.
In these fields you can use the @name
token to refer to the current name of the prim, or you can use pattern matching where an asterisk (*
) represents a any run of characters.
In New Name, you can also use the @index
token to represent he position of the prim in the selection (for example, for the first selected prim @index
will be 0
, for the second prim @index
will be 1
, and so on).
The following examples show how to do different types of renaming using either @name
or *
patterns.
To do this |
Old Name |
New Name |
---|---|---|
Replace the old names with a new name and number |
|
|
Add a prefix |
|
|
Add a suffix |
|
|
Replace a prefix |
|
|
Replace the suffix of names that start with |
|
|
Old Name
When Operation is Rename Primitives, set this to pattern match the old name. For example, to rename all prims that end in _left
to end in _right
, set the Old name to *_left
and the New Name below to *_right
.
New Name
When Operation is Rename Primitives, set this parameter to match the new name. In this field, @name
represents the old name, and @index
represents the position of the prim in the selection (for example, for the first selected prim @index
will be 0
, for the second prim @index
will be 1
, and so on). For example, to append _post
to the name of the selected prims, set Old name above to @name
and New Name to @name_post
.
Remove Empty Variants
When Operation is Remove Primitives, remove empty variants and variant sets left over after removing primitives.
Old Variant Set Name
When Operation is Rename Variant Set, rename any variant set with this name on a selected prim to New Variant Set Name.
New Variant Set Name
When Operation is Rename Variant Set, this is the new name for variant sets on the selected prims that match Old Variant Set Name.
Variant Set
When Operation is Remove Variant Set, delete any variant set with this name on any of the selected prims.
See USD composition for information about reference, payload, inherits, and specializes composition arcs.
References
When Operation is Remove References and this is on, remove any references on the selected prims.
Payloads
When Operation is Remove References and this is on, remove any payloads on the selected prims.
Inherits
When Operation is Remove References and this is on, remove any “inherits” relationships on the selected prims.
Specializes
When Operation is Remove References and this is on, remove any “specializes” relationships on the selected prims.