Search Unity

FPS from PlayableBehavior

Discussion in 'Timeline' started by Solovykh, Oct 19, 2017.

  1. Solovykh

    Solovykh

    Joined:
    Aug 28, 2017
    Posts:
    23
    Is it possible to get the FPS of the Timeline the custom playable is playing on from a PlayableBehavior?
     
  2. Solovykh

    Solovykh

    Joined:
    Aug 28, 2017
    Posts:
    23
    Figured it out, you can set it from the playable !
    Code (CSharp):
    1. PlayableDirector director = playable.GetGraph().GetResolver() as PlayableDirector;
    2. TimelineAsset timelineAsset = director.playableAsset as TimelineAsset;
    3. float fps = timelineAsset.editorSettings.fps;