FPS exceeds the setFrameRate on iOS (low-power mode)

Hello,
Due to fps differences for different android/iOS devices, I limited the frame rate to 60 using
cc.game.setFrameRate(60)

It works flawlessly as expected to limit the frame rate.

The issue occurs when iOS (tested on iPhone 6s and iPhone 11 pro latest ios version) is on low-power mode
Without low-power mode, the game runs on 60fps max.
When the low-power mode is on the game exceeds 60 and goes to 90 fps and game becomes jittery

I have attached the cocos stats screenshot for seeing the fps

Note: It is a web-mobile build

I don’t think we have any way of overriding the OS. One of my games behaves a bit different in low power mode.

@jare any thoughts?

Hi, so in low-power mode. Framerates will run to 90 fps by default?
What engine version are you using?

1 Like

@jare Using cocos creator 2.2.2 mac version. By default game fps is 60, while on low power mode it goes to 90. More likely the Physics simulation is also being affected. We encountered same issue with One Plus 7t which runs on 90Hz and on android phones there’s no low power mode enabled.

Any clues?

Thanks, we’ll check it out

Hey guys, we have a deadline coming up, any help as soon as possible will be appreciated.

Hi, we figured out that this is a bug of Safari, safari will run on 90 fps in low power mode. We have no idea how to fix it. Sorry!

@jare The same bug is occurred for latest 90hz and 120 hz android devices as well

Extract from https://docs.cocos.com/creator/manual/en/physics/physics/physics-manager.html

The Physics System updates the physical world according to a fixed timestep, the default timestep is the frame rate of your game: 1/framerate .

I Would recommend you try to tweak the physics engine to use fixed timestep so you dont’ see this issue.

1 Like