PasteAllAnimation

PasteAllAnimation

詳細

クリップボード内のすべてのアニメーション(「CopyAllAnimation2」を参照)を、指定されたオブジェクトの下に貼り付けます。

スクリプト構文

PasteAllAnimation( InputObjs, [UsePosition] );

パラメータ

パラメータ タイプ 説明
InputObjs オブジェクト名または Pset (任意の選択可能なもの) アニメーションをペーストしたいオブジェクト(または Pset)
UsePosition Boolean TRUE を設定すると、ターゲットのアニメート可能パラメータの順序で、アニメーション ソースがコピーされます。

デフォルト値: 0

VBScript の例

'

' Animate a path-constrained null. Then, copy and paste this 

' animation onto another (unanimated) path-constrained null.

'

dim oCircle1,oCircle2,oColl

dim oNull1,oNull2

'

' Create two ellipses and put them side by side.

'

set oCircle1 = CreatePrim("Circle", "NurbsCurve")

Rotate oCircle1, 90, 0, 0, siRelative, siAdd, siObj, siXYZ

Scale oCircle1, 1, 0.25, 1, siRelative, siLocal, siObj, siXYZ

'Make a duplicate copy of the circle.

set oColl = Duplicate(oCircle1, 1 , _

				 siDuplicateHistory, _

				 siSharedParent, _

				 siShareGrouping, _

				 siDuplicateProperties, _

				 siDuplicateAnimation, _

				 siShareConstraints, _ 

				 siSetSelection, _

				 siApplyRepeatXForm)

'Get the duplicated circle

set oCircle2 = oColl(0)

'Separate the circles

Translate oCircle1 , 0, 0, -2, siAbsolute, siView, siObj, siXYZ

Translate oCircle2 , 0, 0, 2, siAbsolute, siView, siObj, siXYZ

'

' ApplyPath will path-constrain the null to the circle and animate it

' to travel the entire length of the curve. Copy this animation.

'

set oNull1 = GetPrim("Null")

ApplyPath oNull1, oCircle1, 1, 100, 2, False, False

CopyAllAnimation2 oNull1, siAnySource, siAllParam, False

'

' Create a second null, apply a path constraint 

' (no animation), then paste the animation from oNull1

'

set oNull2 = GetPrim("Null")

ApplyCns "Path", oNull2, oCircle2

PasteAllAnimation oNull2

'

' show the constraint relation in top view of viewport A

'

SetValue "Views.ViewA.TopCamera.camvis.*constraint*", True

'

' Play animation to show that it has been copied

'

PlayForwardsFromStart

関連項目

CopyAllAnimation CopyAnimation PasteAnimation CopyAllAnimation2