Timeline Mixer Documentation
TimelineMixer.PlayableNode Class Reference

A wrapper for Playables that allows some reverse traversal of the playable graph, and easy disconnection / reconnection of timeline track ports More...

Public Member Functions

List< int > GetListConnectedInputs ()
 Lets you obtain a list of connected inputs. More...
 
int GetTrackPort (TrackAsset trackAsset)
 Allows you to find out what port corresponds to a given trackAsset. Use ONLY if this node is wrapping a TimelinePlayable. More...
 
bool IsPortConnected (int port, bool isOutputPort)
 Query a port for its connection status. More...
 
int GetConnectedInputCount ()
 Gets a count of all connected inputs. More...
 
void DisconnectTrack (TrackAsset track)
 Pass in a trackasset to disconnect the corresponding output. More...
 
int GetOutputCount ()
 
void AddInput (PlayableNode sourceNode, int sourceOutputPort, float weight=0f, bool useAvailiablePorts=true)
 Create a new connection. If there is a free port to connect to, that will be used instead of creating a new one. More...
 
float GetInputWeight (int port)
 Get the current weight of an input port. More...
 
Playable GetPlayable ()
 Get the wrapped Playable More...
 

Public Attributes

Action OnConnectInput
 Event triggered by a new connection.
 
Action OnDisconnectInput
 Event triggered by a new disconnection.
 

Properties

string Name [get, set]
 Set the Name of the node.
 

Detailed Description

A wrapper for Playables that allows some reverse traversal of the playable graph, and easy disconnection / reconnection of timeline track ports

Member Function Documentation

◆ AddInput()

void TimelineMixer.PlayableNode.AddInput ( PlayableNode  sourceNode,
int  sourceOutputPort,
float  weight = 0f,
bool  useAvailiablePorts = true 
)
inline

Create a new connection. If there is a free port to connect to, that will be used instead of creating a new one.

Parameters
sourceNodeThe PlayableNode to be connected
sourceOutputPortThe output port on the source node that will be connected
weightThe weight of this connection. 0 = no effect, 1 = full effect.

◆ DisconnectTrack()

void TimelineMixer.PlayableNode.DisconnectTrack ( TrackAsset  track)
inline

Pass in a trackasset to disconnect the corresponding output.

Parameters
trackThe trackAsset to disconnect.

◆ GetConnectedInputCount()

int TimelineMixer.PlayableNode.GetConnectedInputCount ( )
inline

Gets a count of all connected inputs.

Returns
Returns an int value of the total amount of connected inputs.

◆ GetInputWeight()

float TimelineMixer.PlayableNode.GetInputWeight ( int  port)
inline

Get the current weight of an input port.

Parameters
portThe port to query.
Returns
Returns a float value 0 - 1

◆ GetListConnectedInputs()

List< int > TimelineMixer.PlayableNode.GetListConnectedInputs ( )
inline

Lets you obtain a list of connected inputs.

Returns
Returns a List<int> of connected input ports.

◆ GetOutputCount()

int TimelineMixer.PlayableNode.GetOutputCount ( )
inline

Returns

◆ GetPlayable()

Playable TimelineMixer.PlayableNode.GetPlayable ( )
inline

Get the wrapped Playable

Returns
Returns the Playable this node represents

◆ GetTrackPort()

int TimelineMixer.PlayableNode.GetTrackPort ( TrackAsset  trackAsset)
inline

Allows you to find out what port corresponds to a given trackAsset. Use ONLY if this node is wrapping a TimelinePlayable.

Parameters
trackAssetThe TrackAsset that should have a port allocated on this TimelineNode
Returns

◆ IsPortConnected()

bool TimelineMixer.PlayableNode.IsPortConnected ( int  port,
bool  isOutputPort 
)
inline

Query a port for its connection status.

Parameters
portThe port to query.
isOutputPortTrue if finding information about an output port.
Returns
Returns true or false, depending if the given port is connected or not.