Search Unity

Culling kills performance

Discussion in 'iOS and tvOS' started by ElKrullo, Jul 14, 2015.

  1. ElKrullo

    ElKrullo

    Joined:
    Feb 24, 2013
    Posts:
    17
    Hello!

    I am working on my first game. A 2D game for iOS where you explore the world by swiping it sideways. The world is made up of a bunch of hills side by side. These hills have different objects on them, like trees, flowers, buildings and such.

    It used to run at 60 FPS on iPad mini 1st gen. But as we have added a lot of sprites and other game objects the frame rate has dropped considerably. We have around 2500 game objects in the scene right now and would like to add a lot more details to the level. I have a feeling this might be too much. The project has been upgraded from Unity 4.6 Mono to 5 and IL2CPP, and I'm not sure if this might have slowed things down also.

    From profiling I can see that culling is a big bottle neck. We get all these spikes where Camera.Renderer > Culling > SceneCulling > WaitingForJob takes up to 330ms.

    Any ideas on things I can try to solve this?
     
  2. Hagen

    Hagen

    Joined:
    Aug 16, 2014
    Posts:
    36
    did you get it to solve?
     
  3. bluescrn

    bluescrn

    Joined:
    Feb 25, 2013
    Posts:
    642
    If you have a lot of small static meshes, can you merge them? Even with static batching enabled, I believe it culls individual meshes within a batch.

    Or can you manually disable groups of objects when you know that they're well off-screen - so Unity has less objects to process?
     
  4. povilas

    povilas

    Unity Technologies

    Joined:
    Jan 28, 2014
    Posts:
    427
    Could you please submit a bug report and attach a reproduction project? Could you post the id of the new bug here? Thanks.