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

Very high CPU Usage and low fps - Render Transparent Geometry

Discussion in '2D' started by DarkCooker, May 10, 2016.

  1. DarkCooker

    DarkCooker

    Joined:
    Jan 7, 2015
    Posts:
    119
    I have a game which many 2d objects with sprite render - about 200-300.
    And the CPU is very high (about 65% goes to Render Transparent Geometry)
    Fps looks bad and the android mobile is hot.

    the draw call (set pass call) is about 140-160

    the game object is difficult to reduce because due to game play's design.
    Is there any possible way to reduce this cpu usage for better fps?

    many thanks!
     
  2. DarkCooker

    DarkCooker

    Joined:
    Jan 7, 2015
    Posts:
    119
    I have used Sprites Altas and turn all textures to 16bits.
    The total memory usage is about 45 mb for textures
     
  3. jc-drile77

    jc-drile77

    Joined:
    Jul 1, 2014
    Posts:
    229
  4. DarkCooker

    DarkCooker

    Joined:
    Jan 7, 2015
    Posts:
    119
    Thanks for the suggestion.

    It is 2D pixel games using SpriteRender and Unity UI.
    We have already disabled mip maps and set the filter mode to Point for some items. (some cannot be set).

    Any more advice that we may miss? Thanks!
     
  5. jc-drile77

    jc-drile77

    Joined:
    Jul 1, 2014
    Posts:
    229
    How big are the texutures that you are using?
     
  6. DarkCooker

    DarkCooker

    Joined:
    Jan 7, 2015
    Posts:
    119
    Currently in the scene, there are 3-4 sprite packs in 1024x 512; 3-4 sprites in 512x512; total 7-8 big packs of sprites
     
  7. jc-drile77

    jc-drile77

    Joined:
    Jul 1, 2014
    Posts:
    229
    Hmmmm, do you have a lot of gameObjects with their scale changed (different than (1,1,1)) if so, it´s better to have the pixels to units changed on the proyect (if different instances of a sprite have different scales they cant be batched).
    Do you notice any loss of quality in the artwork if you shrink it to a lower resolution? (on mobile that is your target platform)
    Did you check Edit> Proyect Settings > Quality? Be sure to be using the right one for android (I usually go for a modified fastest)
    Have you tried usinng the spritepacker? It should be the same as sprite atlases tho,
    Are your atlases done in order to not to have sprites that wont be used in the scene?

    I cant help more than that :(
     
  8. DarkCooker

    DarkCooker

    Joined:
    Jan 7, 2015
    Posts:
    119
    thanks for your advices

    Most of those i have done except scale all items into 1,1,1
    I will check this part to see
     
  9. tomerpeledNG

    tomerpeledNG

    Joined:
    Jul 14, 2017
    Posts:
    81
    Did you managed to solve it?
    Any tips?
     
  10. LeleUnity

    LeleUnity

    Joined:
    Jul 30, 2016
    Posts:
    97
  11. urmund

    urmund

    Joined:
    May 25, 2013
    Posts:
    2
    bump! any other tips would be highly appreciated