Introduced
3.0
Description
Instantiates objects, with options for multiple instances and additional transform controls.
Scripting Syntax
Instantiate( [InputObjs], [NbItems], [Hierarchy], [Grouping], [Selection], [Xfrom], [Sx], [Sy], [Sz], [Rx], [Ry], [Rz], [Tx], [Ty], [Tz], [TrackXform] )
Parameters
|
Parameter |
Type |
Description |
|
InputObjs [in/out] |
List of objects to instantiate Default Value: Current selection |
|
|
NbItems [in/out] |
Number of instances to create Default Value: 1 |
|
|
Hierarchy [in/out] |
How to parent instances Default Value: siNoParent |
|
|
Grouping [in/out] |
How to group instances Default Value: siNoGrouping |
|
|
Selection [in/out] |
How to select instances Default Value: siSetSelection |
|
|
Xfrom [in/out] |
How to distribute instances using transform Default Value: siGlobalXForm |
|
|
Sx [in/out] |
Number |
Scaling x value Default Value: 1.0 |
|
Sy [in/out] |
Number |
Scaling y value Default Value: 1.0 |
|
Sz [in/out] |
Number |
Scaling z value Default Value: 1.0 |
|
Rx [in/out] |
Number |
Rotation x value Default Value: 0.0 |
|
Ry [in/out] |
Number |
Rotation y value Default Value: 0.0 |
|
Rz [in/out] |
Number |
Rotation z value Default Value: 0.0 |
|
Tx [in/out] |
Number |
Translation x value Default Value: 0.0 |
|
Ty [in/out] |
Number |
Translation y value Default Value: 0.0 |
|
Tz [in/out] |
Number |
Translation z value Default Value: 0.0 |
|
TrackXform [in/out] |
Track placement. Default Value: True |
Return Value
Returns an XSICollection object that contains the list of instances.
Examples
VBScript Example
' Create 6 instances ' Position them 3 units apart (each duplicate will be translated 3 units along the X axis from its predecessor) ' The transforms are applied relative to the previous duplicate ' For example, if the original is positioned at (0,0,0), then the duplicates are positioned at ' (3,0,0), (6,0,0), (9,0,0),..., (18,0,0) dim object, list set object = CreatePrim( "Sphere", "NurbsSurface" ) SetValue object & ".sphere.radius", 1.000 CreateModel "Sphere" Instantiate "Model", 6, -1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 3, 0, 0, True
See Also
Autodesk Softimage v7.5