Built-in Op Types

Op Type

Summary

DecomposeTransform

Decomposes a transform group into components.

EditTransform

Modifies transform components.

LightsDefaultValuesBackup

Runs through the locations under the baking root and storeslight linking information in attributes.

LightsDefaultValuesRestore

Restores the light linking information in the lightList foundon any location the op is run onto.

LiveAttribute

Duplicates an attribute at a location and applies an override to it.

MaterialSoloResolve

A resolver for solo materials.

NetworkMaterialMultiSplice

Allows you to make changes to multiple existing NetworkMaterials by connecting or inserting new shading nodes within the shading network.

PolymeshFacesetResolve

Bakes the geometry of faceset children of polymesh scenegraph locations.

ReverseNormals

Reverses point and vertex normals.

Transform

Applies a 3D transform

DecomposeTransform

Decomposes a specific transform group attribute into transform components translation, rotation and scale, based on the ‘mode’ Op argument.

Op Args

Type

Name

Widget Hint

Description

string

locationPath

scenegraphLocation

Scene graph location to be used to retrieve the transform group to be decomposed.

string

rotationOrder

popup

Defines the rotation order to be used to decompose the transform attributes. Valid values are: ‘XYZ’, ‘XZY’, ‘YXZ’, ‘YZX’, ‘ZXY’, ‘ZYX’.

string

mode

popup

Defines how the Op will operate to decompose the transform attributes. Supported modes are: ‘global’, ‘local’, ‘childByName’ and ‘default’. ‘global’ will decompose the global transformation for the target location taking into account parents transforms. ‘local’ will decompose the whole ‘xform’ group set on the target location only. ‘childByName’ will decompose a specific child of the ‘xform’ group. ‘default’ won’t decompose any transform, it will provide transform components from a ‘decomposed’ identity matrix.

string

xformChildName

Specifies the name of the ‘xform’ group attribute’s child to be decomposed. This arguments is only meaningful when the ‘mode’ argument is set to ‘childByName’.

int

setHints

If set to ‘1’, forces to Op to create ‘meta’ attributes to describe hint strings for the decomposed transform component attributes.

Input Attributes

Type

Name

Description

group

xform

Read at location specified by the ‘locationPath’ Op argument. Represents the transform group to be decomposed into translate, rotate and scale components.

Output Attributes

Type

Name

Description

double

decomposedXform.xform.translate.x

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘x’ component of the ‘translate’ vector of the decomposed transform group.

double

decomposedXform.xform.translate.y

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘y’ component of the ‘translate’ vector of the decomposed transform group.

double

decomposedXform.xform.translate.z

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘z’ component of the ‘translate’ vector of the decomposed transform group.

double

decomposedXform.xform.rotate.x

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘x’ component of the ‘rotate’ vector of the decomposed transform group.

double

decomposedXform.xform.rotate.y

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘y’ component of the ‘rotate’ vector of the decomposed transform group.

double

decomposedXform.xform.rotate.z

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘z’ component of the ‘rotate’ vector of the decomposed transform group.

double

decomposedXform.xform.scale.x

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘x’ component of the ‘scale’ vector of the decomposed transform group.

double

decomposedXform.xform.scale.y

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘y’ component of the ‘scale’ vector of the decomposed transform group.

double

decomposedXform.xform.scale.z

Written at location specified by the ‘locationPath’ Op argument. Represents the ‘z’ component of the ‘scale’ vector of the decomposed transform group.

EditTransform

Modifies transform components (translate , rotate, scale) or the whole transform group on a target location.

Op Args

Type

Name

Widget Hint

Description

string

locationPath

scenegraphLocation

Scene graph location where to edit transform components.

string

rotationOrder

popup

Defines the rotation order to be used to decompose the transform attributes that will be modified. Valid values are: ‘XYZ’, ‘XZY’, ‘YXZ’, ‘YZX’, ‘ZXY’, ‘ZYX’.

group

xform

Defines the source transform group whose components will be used to modify the current transform attributes on the target location, according to the ‘mode’ argument. ‘xform’ must have a child group attribute for each transform component ‘translate’, ‘rotate’ and ‘scale’.

string

mode

popup

Defines how the Op will operate to modify the transform components. Supported modes are: ‘replace’, ‘add’, and ‘override’. ‘replace’ will replace the whole ‘xform’ group on the target location with the provided values (see the description of the ‘xform’ Op argument), assuming they represent a global transformation. It will calculate the global transform for the target’s parent location, will invert it and then will apply the resulting inverse matrix, concatenating the transform components calculated from the Op arguments. ‘add’ will add a new transform group, calculated from the Op arguments, to the current ‘xform’ group on the target location. ‘add supports two further options: ‘stackOrder’ which defines the position of the new transform group on the transform stack (valid values are ‘first’ or ‘last’) and ‘xformGroupName’ which defines the name of the new group to be created. Finally ‘override’ will override a specific ‘xform’ group child attribute. The child’s name can be specified using the ‘xformGroupName’ Op argument.

string

xformChildName

Specifies the name of the ‘xform’ group attribute’s child to be created or overridden.

string

stackOrder

Defines the position, on the transform stack, where to add a new transform group. This arguments is only meaningful if the ‘mode’ argument is set to ‘add’.

Output Attributes

Type

Name

Description

double

xform.parentInverse

Written at location specified by the ‘locationPath’ Op argument. Represents the global inverse matrix calculated for the target location. It’s meant to reset the current transformation. This attribute will be set only if the ‘mode’ Op argument is set to ‘replace’.

double

xform.<groupName>.translate.x

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘x’ component of the ‘translate’ vector of the computed transform group.

double

xform.<groupName>.translate.y

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘y’ component of the ‘translate’ vector of the computed transform group.

double

xform.<groupName>.translate.z

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘z’ component of the ‘translate’ vector of the computed transform group.

double

xform.<groupName>.rotate.x

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘x’ component of the ‘rotate’ vector of the computed transform group.

double

xform.<groupName>.rotate.y

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘y’ component of the ‘rotate’ vector of the computed transform group.

double

xform.<groupName>.rotate.z

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘z’ component of the ‘rotate’ vector of the computed transform group.

double

xform.<groupName>.scale.x

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘x’ component of the ‘scale’ vector of the computed transform group.

double

xform.<groupName>.scale.y

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘y’ component of the ‘scale’ vector of the computed transform group.

double

xform.<groupName>.scale.z

Written at location specified by the ‘locationPath’ Op argument. Represents the overridden ‘z’ component of the ‘scale’ vector of the computed transform group.

LightsDefaultValuesBackup

LightsDefaultValuesBackup - Iterates through all locationsunder the baking root looking for light linking information to store as GroupAttributes on the same locations. This Op must run before baking, and it works in cooperation with LightsDefaultValuesRestore. This op expects a StringAttribute|bakingRoot| with all the baking roots, and an optional |CEL|StringAttribute.

LightsDefaultValuesRestore

LightsDefaultValuesRestore - should run after a lookFile has beenresolved to re- build the absolute paths that are found in thelightList(s). The Op assumes that LightsDefaultValuesBackup wasrun before baking. LightsDefaultValuesRestore expects aStringAttribute |bakingRoot| with a single value for the locationwhere the lookFile was assigned.

LiveAttribute

This is an op whose purpose is to copy an existing attribute to a new group attribute under ‘liveAttributes’ and then override specific parts of that attribute. The attribute to override and its value is passed in via the op args along with the location to work on.

Op Args

Type

Name

Widget Hint

Description

string

rootAttribute

scenegraphLocation

The name of the top-level attribute, below which live attribute overrides are stored. (default: ‘liveAttributes’)

group

liveAttrs

Defines one or more live attributes and locations where they should be set. The GroupAttribute should have one or more children. Each child should contain a StringAttribute named ‘location’ and another GroupAttribute named ‘attributes’. location - specifies the scene graph location to apply the live attribute. attributes - specifies the attribute values to override at this location.

MaterialSoloResolve

This is a resolver for the material soloing feature of network materials, it runs at all locations searching for a top-level attribute named ‘soloMaterial’. If found, the ‘soloMaterial’ attribute will be renamed to ‘material’, overwriting any existing ‘material’ attribute.

Input Attributes

Type

Name

Description

group

soloMaterial

A version of a ‘material’ attribute where shading node soloing has occurred.

NetworkMaterialMultiSplice

This op allows you to make modifications to multiple NetworkMaterials at the same time by only matching the base name of the node being connected to (that is, the name of the node without any trailing numbers). To match by base name, add a ‘*’ to the end of the node name, e.g. surfaceShader*. This Op is also compatible with the material.layout attribute, allowing the use of nodes such as NetworkMaterialEdit downstream.

Op Args

Type

Name

Widget Hint

Description

string

CEL

cel

CEL expression to match locations where the splice should occur.

string

spliceLocation

scenegraphLocation

The scene graph location containing the material being spliced in.

group

connections

Specifies a new connection to be made between any nodes in the source or spliced material. The GroupAttribute should contain four child StringAttributes named connectFromNode, connectFromPort, connectToNode and connectToPort. If connecting to a terminal on the material, use the node name ‘<material>’

group

disconnections

Specifies a disconnection to be made. The GroupAttribute should contain two child StringAttributes named ‘node’ and ‘port’. The port should be an input port on ‘node’. If disconnecting from a terminal on the material, use the node name ‘<material>’

PolymeshFacesetResolve

PolymeshFacesetFilter - Converts a polymesh scenegraph location with faceset children into a group scenegraph location with polymesh children. Each polymesh child is a duplicate of the original polymesh geometry containing only the faces specified in the original faceset data. Any unused faces will be appended in an extra child sibling named ‘__unusedFaces’, to ensure the entire original polymesh is rendered.

ReverseNormals

Finds any geometry.point.N or geometry.vertex.N attributes at matching locations and inverts their direction.

Op Args

Type

Name

Widget Hint

Description

string

CEL

cel

CEL expression to match locations against.

Input Attributes

Type

Name

Description

float

geometry.point.N

Read at locations that match the CEL expression. If this attribute exists, its direction is reversed and the attribute is overridden with the result.

float

geometry.vertex.N

Read at locations that match the CEL expression. If this attribute exists, its direction is reversed and the attribute is overridden with the result.

Output Attributes

Type

Name

Description

float

geometry.point.N

Written at locations that match the CEL expression, if there was an incoming attribute of the same name. The written value will be the inverse of the attribute from the input scene. If no attribute with the same name was found in the input scene, no output attribute will be created (and no error raised)

float

geometry.vertex.N

Written at locations that match the CEL expression, if there was an incoming attribute of the same name. The written value will be the inverse of the attribute from the input scene. If no attribute with the same name was found in the input scene, no output attribute will be created (and no error raised)

Transform

Adds transform attributes to Scene Graph locations allowing you to control 3D objects in the Viewer.

Op Args

Type

Name

Widget Hint

Description

string

locationPath

scenegraphLocation

The scene graph location to operate on.

group

xform

The transformation to apply, in its deconstructed form (that is, individual attributes for rotate/scale/translate, not a 16x16 matrix). This GroupAttribute can have arbitrary hierarchy. Only recognised attribute names will cause transformations to be applied. These are: ‘scale*’, ‘translate*’ and ‘rotate*’. Other names for attributes are allowed, but will be ignored when the transform is applied.

double

pivot

The x/y/z pivot to apply the transformation with.

int

makeInteractive

Whether the transform created should be marked as interactive or not. If enabled, the resulting transform will be named xform.interactive, and the attributeEditor.xform.exclusiveTo attribute will be created using the ‘xformExclusiveTo’ opArg.

int

adjustParentBounds

When enabled, this will adjust the “bound” attribute of parent locations affected by the transformation of the child. As this calculation can lead to deeper scene traversal from shallow locations, it can be expensive in many cases (particularly when many of these Ops are contributing to the scene). When you know you don’t need it, set this to 0 for increased performance.

string

xformExclusiveTo

The name of the node to set exclusivity on. This is only used when the opArg ‘makeInteractive’ is also set to 1. When both opArgs are given, an attribute named ‘attributeEditor.xform.exclusiveTo’ will be created with the value provided to the opArg ‘xformExclusiveTo’.

int

applyFirst

Affects the position in the existing xform stack that the transform will be created at. When applyFirst=1, the transformation will be added to the top of the xform stack. When applyFirst=0, the transformation will be added to the bottom of the xform stack.

Input Attributes

Type

Name

Description

group

xform

The existing transformation to append/prepend to. When the incoming scene graph data already has an xform attribute group, the Op will append/prepend its xform to this group.

double

bound

The bounding box attribute. This is only queried when the ‘adjustParentBounds’ opArg is 1. This is queried in order to pad the bounding box(es) to account for the transformation being applied. This is queried at all locations from the root, to the target locationPath (inclusive).

Output Attributes

Type

Name

Description

group

xform

The transform stack. This incorporates and modifies the input scene graph’s xform stack, applying the provided ‘xform’ opArg at the appropriate position, dependent on other opArgs.

string

attributeEditor.xform.exclusiveTo

Set when the ‘makeInteractive’ opArg is 1, and a value has been provided for the ‘xformExclusiveTo’ opArg. When that’s the case, the value of this attribute will be the value provided to the’xformExclusiveTo’ opArg. This is used to provide manipulators in the viewer that feed data back into the relevant node.

double

bound

The bounding box attribute. This is only set when the ‘adjustParentBounds’ opArg is 1. This is set in order to pad the bounding box(es) to account for the transformation being applied. This is set at all locations from the root, to the target locationPath (inclusive).