public void StartRecording()
        {
            recording = CreateInstance();

            startTimeSec       = Time.realtimeSinceStartup;
            isRecordingStarted = true;
            isPaused           = false;
        }
 public bool RecordingChanged()
 {
     if (watchReference == recording)
     {
         return(false);
     }
     else
     {
         watchReference = recording;
         return(true);
     }
 }
Пример #3
0
        public override Playable CreateTrackMixer(PlayableGraph graph, GameObject go, int inputCount)
        {
            foreach (var clip in GetClips())
            {
                RecordingClip recordingClip = clip.asset as RecordingClip;
                RecordingBase recordingRef  = recordingClip.template.recording;
                if (recordingRef)
                {
                    if (recordingClip.template.RecordingChanged())
                    {
                        clip.displayName = recordingRef.name;
                        clip.duration    = recordingClip.duration;
                        clip.clipIn      = 0;
                    }
                }
                else
                {
                    clip.displayName = "...";
                }
            }

            return(ScriptPlayable <RecordingMixerBehaviour> .Create(graph, inputCount));
        }
 public void CleanClone(RecordingBehaviour other)
 {
     watchReference = other.watchReference;
 }
 private void ResetRecorder()
 {
     isPaused  = isRecordingStarted = false;
     doCancel  = doSave = doRecord = false;
     recording = null;
 }