Search Unity

  1. Unity 2020 LTS & Unity 2021.1 have been released.
    Dismiss Notice

OpenGLES 3.1 halves FPS vs 3.0/2.0 on Android

Discussion in '5.5 Beta' started by ZaZy, Oct 27, 2016.

  1. ZaZy

    ZaZy

    Joined:
    Jan 14, 2015
    Posts:
    20
    Forcing OpenGLES3 on an Android device supporting 3.1 (i.e HTC 10) causes a significant frame rate drop compared to OpenGLES2.

    I have uploaded a simple test scene with a bug report, case 845533. The test scene contains quite a few spheres using the standard secular shaded with a diffuse and normal texture (shininess at 0.85 for reflections). I also added a few lights to ensure I had a frame rate just under 30 fps to better demonstrate the issue. All scene/project settings are default (no precomputed real time or baked GI, gamma color space etc) except I used the 'good' quality setting to get more than 1 pixel light.

    When built to a HTC 10 device, the scene renders at approximately 25 FPS when forcing OpenGLES3 and just above 50 FPS when forcing OpenGLES2 with no visible quality difference. Even more surprisingly, tapping the screen or holding down a finger on the screen increases the frame rate (I'm not kidding).

    Building the scene to older Android hardware that only supports OpenGL ES 3.0 (i.e HTC One M7) does not produce this behaviour. The frame rate in this case is the same when forcing either OpenGLES3 or 2 and tapping the screen has no effect on frame rate.

    I have not been able to test this on other high performance android mobile devices (e.g Samsung Galaxy S7). Perhaps other beta users can share their experience with such devices.

    I would appreciate any feedback on this issue via this thread.
     
    MrEsquire likes this.
  2. ZaZy

    ZaZy

    Joined:
    Jan 14, 2015
    Posts:
    20
    Sorry. Forgot to mention I can reproduce this issue on 5.5.0b8 and also 5.4.1p4
     
    MrEsquire likes this.
  3. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    988
  4. ZaZy

    ZaZy

    Joined:
    Jan 14, 2015
    Posts:
    20
    Thanks for pointing me to that thread, I wasn't aware of that one.

    Unfortunately I have discounted most of the common causes mentioned there through my testing over a number of days, such as different vsync options / UI completely removed / multithreading / lower resolutions / shadows / batching etc etc. The case I submitted is the simplest scene I could reproduce the issue with, just standard settings and shaders (although I have tried many other permutations).

    I also changed the title of this thread to be more explicit. The point I should have made more clear is I only see this issue on my device supporting OpenGL ES 3.1 whereas my older device does not have the issue on 3.0. So this particular issue is either to do with the 3.1 render pipeline implementation (if it is different), the more recent hardware or perhaps Android 6.0 (older phone uses Android 5.0).

    But I will still work my way through the 600+ posts in that thread you pointed me to over the weekend to make sure I didnt miss a more basic cause of the issue.
     
  5. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    988
    As far as i know it is up to the pipeline implementation but it is hardware related... i think the one of the reasons for a low fps was an additional Blit to the screen... if i am wrong please someone to correct me!
    The low fps is shown only on some devices... I am having Lenovo phone which runs a small game at 22 fps... And the same game runs at about 55 fps on older GLES 2.0 phone...

    I will give you some tips that i discovered improving things...
    1. First and most important to me was removing any specular shader... it was the main thing ruing the fps
    2. If having a second enabled canvas, the fps gets low as well
    3. Terrain was very heavy when using spec shader... but with lower settings and a mobile diffuse shader was better.

    Taking care of these things set the fps back to around 50-55 - but graphics quality suffered a lot..
     
  6. MrEsquire

    MrEsquire

    Joined:
    Nov 5, 2013
    Posts:
    2,712
    Or how about Unity work on this instead of us needing to look for solutions.
    Well I shared my thoughts and warn:
    https://forum.unity3d.com/threads/opengl-es-3-0-setting-added-used-by-default-on-android.437464/
     
unityunity