HTML Low FPS

60 fps in config.lua, about 40 frames actually
simple project. on different browsers and versions the same 40 frames
solar supports 60 fps in html?

I’m not sure what the cause is, but the HTML5/Emscripten builds seem to peak at around 50 FPS. I don’t know if it’s due to Emscripten, HTML canvas, JS or something else.


Just a wild uneducated guess, and I don’t even know if this is how the build work, but if Emscripten tries updating the game 60 times per second and it’ll only proceed with the update if Solar2D core is done with the current frame, it would explain why it could never hit 60 FPS.

And it seems that Emscripten is indeed set to run at 60 FPS?

If Solar2D is set to using 30FPS in config.lua, then the frames should always be done with time to spare to meet the 60FPS Emscripten time window. However, if both are set to 60, then either Emscripten has to wait until Solar2D core is done with the frame, which would result in 1 skipped frame every now and then, or maybe Solar2D core would need to wait for Emscripten to finish its processing?

Anyway, just a wild guess.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.