Super fast frame rate?

We’ve isolated it to build Corona 2018.3366 from 2018.09.07. 3365 has the correct frame-rate and 66 onwards appears to be broken.

Interestingly the release notes for 3366 include “Framework: making iterating timer more precise” - looks like this may be the problem @robmiracle ?

Thanks for tracking it down. It seems that it was single line fix in timer framework you’re referring to:

https://github.com/coronalabs/framework-timer/commit/7111d58a44751319a0866b76ccd4a9d7df9d1137

It doesn’t seem to change framerate in any way, but it does have some fixes to “timer” framework.

May I ask you to try saving timer.lua near your main.lua and see if it helps?

Here’s version before the fix: https://raw.githubusercontent.com/coronalabs/framework-timer/ef432e49bf7a8fc5a1d8db29f4532717ba840fc0/timer.lua

Also, you can add this code to beginning of your main.lua

package.loaded.timer = nil timer = require "timer"

That doesn’t fix it - still going flat-out.

OK. I took a deeper look. Unfortunately timer is not reloading like that, but issue is with that change. That change alters the behaviour that timer is invoked only once per frame. FPS are actually stay same, just timer gets fired up quite a bit. I’m looking if there’s a fix for such behaviour.

BTW, here’s code for FPS counter:

local frames = display.newText( "FPS: 00.0", world.x, world.y-160, native.systemFont, 32 ) frames:setFillColor( 0.2, 0.6, 0.8 ) local i = 0 local startTime = 0 function OnFrame( e )     i = i+1     if i == 100 then         frames.text = string.format("FPS: %.1f", 1000\*i/(e.time - startTime))         i=0         startTime = e.time     end end Runtime:addEventListener("enterFrame", OnFrame)

ok thanks.

I committed the fix, it should be fixed in tomorrow’s daily build.

Awesome thanks.

Please, try 3468

Confirmed fixed in 3468. Thanks @vlads  :smiley: