Jump to content

60FPS on mobile and Phaser


Recommended Posts

I'm doing something on Phaser on mobile phones at the moment and am wondering if minimum 60FPS performance is really necessary on mobile devices? Is there any way to play with a lower FPS (maybe down to 30) without the obvious jittering, maybe by forcing a cap on the FPS to a lower average?

Link to comment
Share on other sites

60 FPS should always be your target as thats generally the refresh rate for browsers, although many games can get away with as low as 30 FPS (or possibly less for some games).


Depending on how your are structuring your renders (does Phaser impose this? I'm not sure) you can choose whatever fps you like as so long as everything keeps up you'll get it.


A naive solution using `setInterval` for your tick would look something like:

var FPS = 30function render() { ... }setInterval( render, 1000 / FPS )

I'd still advocate using `requestAnimationFrame`, which calls every 16.6ms if it can, but skip every other call (or do some maths to work out which calls to skip if you want different framerates).

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...