Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Bug PlayableDirector.get_duration() generates garbage

Discussion in 'Timeline' started by Midiphony-panda, Sep 13, 2021.

  1. Midiphony-panda

    Midiphony-panda

    Joined:
    Feb 10, 2020
    Posts:
    234
    Hello ! :)

    upload_2021-9-13_19-53-44.png

    While profiling my prototype on Timeline, I noticed that PlayableDirector.get_duration() is allocating memory. Deep profiling shows that the allocation is caused by PlayableAsset.Internal_GetPlayableAssetDuration().

    Is there a reason why or should it be considered a bug ?


    (I'm trying to squeeze the performance out of Timeline so I might come back with other notes like this :p)
     
  2. grahamsaulnier

    grahamsaulnier

    Unity Technologies

    Joined:
    Apr 10, 2018
    Posts:
    17
    Hello Midiphony-panda,

    We had an internal report of this earlier this year. There is a fix for this in Timeline 1.6.2, which you should be able to get in the package manager with Unity 2020.3.

    I will back-port the fix to Timeline 1.4 and 1.5, but can't give a date for when they will be released.