Search Unity

Access list of clips from script through PlayableDirector

Discussion in 'Timeline' started by edwon, Oct 17, 2017.

  1. edwon

    edwon

    Joined:
    Apr 24, 2011
    Posts:
    266
    Is there a way to access clips and tracks from a MonoBehaviour that is referencing PlayableDirector?

    I want to be able to manipulate the timeline time by searching for clip start times on a track with custom playables on it.
     
  2. Antoine_OSG

    Antoine_OSG

    Joined:
    Sep 2, 2016
    Posts:
    43
    Have you tried this :
    Code (CSharp):
    1. foreach (var track in timelineAsset.GetOutputTracks())
    2.         {
    3.             foreach (var clip in track.GetClips())
    4.             {
    5.  
    6.             }
    7.         }
     
    stefan-velnita and NatCou like this.