Applies an operator on a single object. ApplyOperator acts on one input object at a time (it only creates and connects one operator at a time). To apply the same operator to multiple objects at once, use ApplyOp instead. For a list of available operators, see OpPreset.

This command supports both group-level and port-level ConnectionSets. The syntax for group-level and port-level connection sets differs slightly in that group-level connection sets can accept objects and resolve the underlying port connections. For more information, see the ConnectionSet topic.

Note: ApplyOperator doesn't create output objects. It expects them to be supplied in the connection set or the input list.

Scripting Syntax

oReturn = ApplyOperator( PresetObj, [ConnectionSet], [ConnectType] );

Return Value

Returns the Operator Name of the newly created operator.


Parameter Type Description
PresetObj String or a preset object (for example, an object obtained from SIGetPreset) An Operator Preset.
ConnectionSet ConnectionSet Specifies the objects connected to an operator. See Operator Presets for details on the connection set required for this operator.

Default Value: Current selection

Warning: An error occurs if the connection set is invalid. Please verify the connection set required for this operator to avoid breaking your scripts.

ConnectType siBranchFlag Specifies the type of connection.

Default Value: siUnspecified


VBScript Example

' Apply a twist to a single object
CreatePrim "Sphere", "MeshSurface"
set twistop = ApplyOperator( "Twist", "Sphere")
Application.LogMessage twistop
SetValue twistop & ".angle", 30
'INFO : "sphere.polymsh.twistop"
SetValue "sphere.polymsh.twistop.angle", 30

See Also

ApplyOp ApplyGenOp ApplyTopoOp ApplyHairOp Operator