0 Replies
      Latest reply on Feb 11, 2018 7:29 PM by ElectricToy
      ElectricToy Level 1 Level 1 (0 points)

        My game exhibits an occasional slow down that is very predictable and easy to reproduce (iOS 11): it happens when Night Shift is transitioning from day to night mode or back again.

         

        To reproduce:

         

        1. In Settings, set night shift to be off.

        2. Set night shift to turn on about one minute after the current time.

        3. Run the game.

        4. When the target time arrives, night shift will begin to transition: the color of the screen will slowly change..

         

        Expected result:

         

        The game continues to run at 60 frames per second (as controlled by a CADisplayLink object).

         

        Actual result:

         

        The game's frame rate suddenly drops to 30 fps. This continues for about 2 minutes. Just as suddenly, the frame rate automatically returns to 60 fps.

         

        So my theory is that something about Night Shift and my game's rendering cause the frame rate to cut in half precisely during that time when Night Shift is changing from day to night or back again.

         

        This is an OpenGL ES2 game using none of the "Kits" (GameKit, SpriteKit, etc.) and not using Metal.

         

        Any ideas what might cause this performance issue or how to resolve it?