Search Unity

  1. Looking for a job or to hire someone for a project? Check out the re-opened job forums.
    Dismiss Notice
  2. Unity 2020 LTS & Unity 2021.1 have been released.
    Dismiss Notice
  3. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

CPU usage PreLateUpdate.DirectorUpdateAnimationBegin PreLateUpdate.DirectorUpdateAnimationEnd

Discussion in 'Animation' started by ben-maurin, Oct 27, 2017.

  1. ben-maurin

    ben-maurin

    Joined:
    Apr 7, 2016
    Posts:
    47
    Hi,

    I have a CPU issue using Animator. I only use it for small or UI objects, with no sprite modification, no root motion (it still appears in profiler). Generally it's only for changing the state of an objet (the animators are always stuck in on state exept on particular event that will trigger an animation that will enable some components or change the alpha of some sprites).

    Here I have an exemple with 7 very simple animators. It cost 0.17ms (DirectorUpdateAnimationBegin )+ 0.15ms (DirectorUpdateAnimationEnd) on PC, and it's 3 times that values on consoles ( 1.5 ms in total !) .

    upload_2017-10-27_10-25-17.png

    The kind of animations they are stuck in :
    upload_2017-10-27_10-40-9.png

    The only way I found is to remove ALL animator. If there is at least one animator this appear and cost a lot.

    Do you have any tips to reduce this cost?

    Thanks
     
  2. FMark92

    FMark92

    Joined:
    May 18, 2017
    Posts:
    1,244
  3. ben-maurin

    ben-maurin

    Joined:
    Apr 7, 2016
    Posts:
    47
    It does not seem really related. The cpu problem come from Animator, not Particle system.
     
  4. FMark92

    FMark92

    Joined:
    May 18, 2017
    Posts:
    1,244
    You're still waiting for job group. I thought it might be.
    Anyway I get 0.06ms on 18 complex animators. So it's not really the kind of slowdown I care about. I can get further optimise my update calls to make the whole thing faster anytime.
     
  5. ben-maurin

    ben-maurin

    Joined:
    Apr 7, 2016
    Posts:
    47
    you get this values with unity 5.3?
     
  6. FMark92

    FMark92

    Joined:
    May 18, 2017
    Posts:
    1,244
    No, I use 2017.1.
     
  7. ben-maurin

    ben-maurin

    Joined:
    Apr 7, 2016
    Posts:
    47
    So I checked with 2017.3, still the same problem.
     
  8. johannesahvenniemi

    johannesahvenniemi

    Joined:
    Feb 17, 2015
    Posts:
    2
    Experiencing the same issue. Only a few animators but DirectorUpdateAnimationBegin and DirectorUpdateAnimationEnd consumes lots of CPU. Using version 2017.2.1.p2. Any news on this?
     
  9. Tortuap

    Tortuap

    Joined:
    Dec 4, 2013
    Posts:
    99
    Same here... 2017.2.1f1
     
  10. yanivng

    yanivng

    Joined:
    May 21, 2017
    Posts:
    43
    Same here, 2018.2.20f1
     
  11. hacky4

    hacky4

    Joined:
    Jul 14, 2017
    Posts:
    1
    2019.1.8f1 same issue
     
  12. Coco07

    Coco07

    Joined:
    Mar 7, 2017
    Posts:
    16
    2020.2.3f1 same issue
     
unityunity