PlayableOutputExtensions

class in UnityEngine.Playables

매뉴얼로 전환

설명

Extensions for all the types that implements IPlayableOutput.

Extension methods are static methods that can be called as if they were instance methods on the extended type.

using UnityEngine;
using UnityEngine.Playables;

public class ExamplePlayableBehaviour : PlayableBehaviour { void Start() { PlayableGraph graph = PlayableGraph.Create(); ScriptPlayableOutput scriptOutput = ScriptPlayableOutput.Create(graph, "MyOutput");

// Calling method PlayableExtensions.SetWeight on ScriptPlayableOutput as if it was an instance method. scriptOutput.SetWeight(10);

// The line above is the same as calling directly PlayableExtensions.SetDuration, but it is more compact and readable. PlayableOutputExtensions.SetWeight(scriptOutput, 10); } }

정적 함수

GetSourceOutputPortReturns the source playable's output connection index.
GetSourcePlayableReturns the source playable.
GetUserDataReturns the opaque user data. This is the same value as the last last argument of ProcessFrame.
GetWeightReturns the weight of the connection from the PlayableOutput to the source playable.
IsOutputNullReturns true if the PlayableOutput is null, false otherwise.
IsOutputValid
SetReferenceObjectSets the bound object to a new value. Used to associate an output to an object (Track asset in case of Timeline).
SetSourceOutputPortSets the source playable's output connection index. For playables with multiple outputs, this determines which sub-branch of the source playable generates this output.
SetSourcePlayableSets which playable that computes the output and which sub-tree index.
SetUserDataSets the opaque user data. This same data is passed as the last argument to ProcessFrame.
SetWeightSets the weight of the connection from the PlayableOutput to the source playable.