Tanoda
MethodRecordingClip.cs
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright (C) Ultraleap, Inc. 2011-2020. *
3 * *
4 * Use subject to the terms of the Apache License 2.0 available at *
5 * http://www.apache.org/licenses/LICENSE-2.0, or another agreement *
6 * between Ultraleap and you, your company or other organization. *
7 ******************************************************************************/
8
9using UnityEngine;
10using UnityEngine.Playables;
11using UnityEngine.Timeline;
12
13namespace Leap.Unity.Recording {
14
15 public class MethodRecordingClip : PlayableAsset, ITimelineClipAsset {
16
17 public bool invokeAtEditTime = false;
18
19 public ClipCaps clipCaps {
20 get {
21 return ClipCaps.ClipIn | ClipCaps.SpeedMultiplier;
22 }
23 }
24
25 public override Playable CreatePlayable(PlayableGraph graph, GameObject owner) {
26 var playable = ScriptPlayable<MethodRecordingPlayable>.Create(graph);
27 playable.GetBehaviour().invokeAtEditTime = invokeAtEditTime;
28 return playable;
29 }
30 }
31}
override Playable CreatePlayable(PlayableGraph graph, GameObject owner)