2

I just created a new project and built an opening scene with a few sprites in it, Same scene ran in unity 4.7 with 60FPS but i cant get it in unity 5.6. I have only one simple script (fps counter), one simple animation(1 leaf), 15 sprites in a scene and canvas with text on it with only 5 draw calls. I even optimized sprite meshes by hand so they have less overdraw. It happens both on android and PC.
With mine fps script and internal profiler:
Unity4.7 > PC 450fps | Android 60fps
Unity5.6 > PC 110fps | Android 35-50fps

These are my settings
Tree and view screenshot
Settings

Here is the FPS script

using UnityEngine;
 using UnityEngine.UI;

 public class FrameCounter : MonoBehaviour
 {
     public float refreshInterval;

     private Text label;
     private float delta;
     private float frames;
     private float res;

     // Use this for initialization
     void Start ()
     {
         label = GetComponent<Text>();
         delta = 0;
         frames = 0;
     }

     // Update is called once per frame
     void Update ()
     {
         frames++;
         delta += Time.deltaTime;

         if (delta > refreshInterval)
         {
             res = delta / frames;
             label.text = 1f / res + " (" + 1000f * res + "ms)";
             delta = 0;
             frames = 0;
         }
     }
 }

After some settings tweaking: turning off 32-bit buffer, deleting OpenGLES2 from graphics API list, setting quality settings to fastest i got some performance boost but not enough. Can't get 60FPS :( Here is the internal profiler results after tweaking:

02-21 04:58:07.719 30216 30291 D Unity   : Android Unity internal profiler stats:
 02-21 04:58:07.719 30216 30291 D Unity   : cpu-player>    min: 12.7   max: 36.4   avg: 20.5
 02-21 04:58:07.719 30216 30291 D Unity   : cpu-ogles-drv> min:  0.0   max:  0.0   avg:  0.0
 02-21 04:58:07.719 30216 30291 D Unity   : gpu>           min:  0.0   max:  0.0   avg:  0.0
 02-21 04:58:07.720 30216 30291 D Unity   : cpu-present>   min: -20.0   max:  1.4   avg: -1.6
 02-21 04:58:07.720 30216 30291 D Unity   : frametime>     min: 13.0   max: 34.6   avg: 18.9
 02-21 04:58:07.720 30216 30291 D Unity   : batches>       min:   5    max:   5    avg:   5
 02-21 04:58:07.720 30216 30291 D Unity   : draw calls>    min:   5    max:   5    avg:   5
 02-21 04:58:07.720 30216 30291 D Unity   : tris>          min:   274  max:   274  avg:   274
 02-21 04:58:07.720 30216 30291 D Unity   : verts>         min:   348  max:   348  avg:   348
 02-21 04:58:07.720 30216 30291 D Unity   : dynamic batching> batched draw calls:  13 batches:   1 tris:   226 verts:   252
 02-21 04:58:07.720 30216 30291 D Unity   : static batching>  batched draw calls:   0 batches:   0 tris:     0 verts:     0
 02-21 04:58:07.720 30216 30291 D Unity   : player-detail> physx:  0.0 animation:  0.0 culling  0.0 skinning:  0.0 batching:  0.3 render: -0.3 fixed-update-count: 0 .. 0
 02-21 04:58:07.720 30216 30291 D Unity   : managed-scripts>  update:  0.0   fixedUpdate:  0.0 coroutines:  0.0
 02-21 04:58:07.720 30216 30291 D Unity   : managed-memory>   used heap: 372736 allocated heap: 512000, max number of collections: 0 collection total duration:  0.0
 02-21 04:58:07.720 30216 30291 D Unity   : ----------------------------------------

Is there something i am doing wrong ?

mkrieger1
  • 19,194
  • 5
  • 54
  • 65

0 Answers0