Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Cinemachine Android 60 fps Tracked Dolly

Discussion in 'Cinemachine' started by usernameHed, Apr 23, 2019.

  1. usernameHed

    usernameHed

    Joined:
    Apr 5, 2016
    Posts:
    93



    Hello, It's been 5 day i'm working on a really weird problems:
    On Android, when I have a tracked dolly activated, my fps drop from 60 to 45. When I am looking deeply into what's going on, Gfx.WaitForPResent seems to wait for... nothing really.

    The spik you see correspond to a transition between a Cinemachine Transposer and a TrackedDolly camera (the spik is always present when i am in the tracked dolly camera, and disapair in other camera mode)

    I have really nothing in my scene... (like one sphere and one plane, not even 5 draw calls, and not so many triangles.

    My cinemachineVirtual Camera is in StandbyUpdate Always (I have to, for transition reason, but even if i change it, nothing change with the fps)
    My Vsync is set to 1. (when I test with no vsync, my framerate is always like 50%, with huge visible spiks)


    If you have any idea of what is going on, why the Gfx.WaitForPResent wait...
    and the answer from here:
    https://github.com/UnityCommunity/U...iler:-Overhead---Gfx.WaitForPresent-explained
    doesn't help us i am afraid.

    Thanks you
     
  2. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,658
    Can you post the inspectors for the path and for the tracked dolly vcam? Also for the CM brain. Thanks
     
  3. usernameHed

    usernameHed

    Joined:
    Apr 5, 2016
    Posts:
    93




    I explain what I'm I doing:
    I have a dollyPath with 10 points, at each point, I have a Cinemachine Virtual Camera who have a tracked dolly and a aim Composer. (the 10 cameras have the same trackedDolly, and each of them have different damping option.


    When my player is between 2 cameras, here the camera VCam1 & VCam2. I have this 2 cameras active with a StandbyUpdate Set to Always (and the other inactive with StandbyUpdate Set to Never)

    In this picture, my VCam1 have a Priority of 12, and the VCam2 a priority of 10.
    When my player is close to VCam2, I Desactivate the VCam1, set the priority of VCam2 to 12, active the VCam3 with priority of 10. And so on.

    So even if 10 virtual trackedDolly Camera with the same dolly seems a lot, i am activating / desactivating them on the fly. And I do everything to gain performance in my scripts. But it seems like Cinemachine doesn't like it.
     
  4. Gregoryl

    Gregoryl

    Unity Technologies

    Joined:
    Dec 22, 2016
    Posts:
    7,658
    Sorry for the delay.

    I'm a little confused about what effect you're trying to achieve with all this.
    Can you describe to me in words the camera behaviour that you want? Maybe you can get it with a simpler setup.

    For the performance: do you have AutoDolly enabled in the vcam TrackedDolly? If so, can you please show me the settings?