Framerate drops to ~45fps on iOS ... sometimes

Discussion about using Moai SDK - post questions, bugs and issues here.

Moderators: seebs, franciscotufro

Framerate drops to ~45fps on iOS ... sometimes

Postby kleibrook » Fri Jul 13, 2012 11:30 pm

I was just playing around with a trivial multi-touch test script in MOAI when I noticed some odd behaviour apparently related to screen orientation. I'm displaying the performance and step values from MOAISim on the screen and while i was poking and swiping, i accidentally rotated the device, and the framerate dropped to about 44fps as reported by MOAISim, which is also consistent with the noticably jerkier touch events I was getting at that time.

If I rotated the device back to the original orientation, fps went back up to 60 and input became smoother again. I could understand if this was an optimization sort of thing, in that certain orientations maybe need more work for doing the rotation, however... I reproduced the problem several times, and the orientations in which the framerate drops may be different every time. If I just keep rotating the device, eventually one or more orientations will begin rendering at 44, and then I can rotate back to a 60fps orientation and it's all good again... back and forth. Sometimes they're all good, others any one or more of the 4 orientations might exhibit the slowdown.

Any thoughts/ideas?

iPhone 4 running iOS 5.1.1 and using the latest packaged build of moai sdk
User avatar
kleibrook
 
Posts: 7
Joined: Wed Jun 20, 2012 11:16 pm

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby dana » Mon Jul 16, 2012 12:48 pm

That is strange, I will look into this and try to reproduce it. Thanks for reporting it.
User avatar
dana
Site Admin
 
Posts: 200
Joined: Fri Mar 02, 2012 6:10 pm
Location: Zipline Games

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby Charles » Wed Jul 18, 2012 3:24 pm

I have been experiencing something very similar. Also on iPod Touch 4th generation.

Have a simple app with a 512x512 MOAI Tile Grid and a map imported from the Tiled Editor. The app allows you to drag the camera across the map using a single touch.

When I open the app on the iPod for the first time, performance is good ( approx 60fps )
I hit the home button on the iPod Touch to "minimize" my app.
I open the app again. performance is bad ( approx 15 fps or less)

Closing and then re-opening the app causes bad performance about 50% of the time
User avatar
Charles
 
Posts: 31
Joined: Wed Feb 15, 2012 12:39 pm

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby dana » Wed Jul 18, 2012 3:40 pm

I was able to reproduce the bug where the fps was dropping when rotated to landscape mode, and I filed a bug for that.

Charles, I couldn't reproduce your bug with exiting to the home screen and re-opening the app. Would you be able to send me a code sample that does it?
User avatar
dana
Site Admin
 
Posts: 200
Joined: Fri Mar 02, 2012 6:10 pm
Location: Zipline Games

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby Charles » Wed Jul 18, 2012 3:47 pm

Yes what's the best way to send it?

If you have an assembla.com account, I can add you to the team.
User avatar
Charles
 
Posts: 31
Joined: Wed Feb 15, 2012 12:39 pm

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby dana » Wed Jul 18, 2012 3:53 pm

How about email? My email is dana@ziplinegames.com
User avatar
dana
Site Admin
 
Posts: 200
Joined: Fri Mar 02, 2012 6:10 pm
Location: Zipline Games

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby kleibrook » Wed Jul 18, 2012 8:57 pm

dana wrote:I was able to reproduce the bug where the fps was dropping when rotated to landscape mode, and I filed a bug for that.


Great, thanks
User avatar
kleibrook
 
Posts: 7
Joined: Wed Jun 20, 2012 11:16 pm

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby Charles » Sun Jul 22, 2012 9:14 am

Hey Dana, I emailed you the code. Did you get a change to look at it?
User avatar
Charles
 
Posts: 31
Joined: Wed Feb 15, 2012 12:39 pm

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby adam » Wed Jul 25, 2012 2:40 pm

We weren't able to reproduce the backgrounding and resuming issue here. I'll be looking into the fps drop on rotation soon.
User avatar
adam
 
Posts: 262
Joined: Wed Sep 14, 2011 11:50 am

Re: Framerate drops to ~45fps on iOS ... sometimes

Postby Charles » Sun Jul 29, 2012 12:32 pm

The frame-rate issue I was experiencing in build #56 seems to be working perfectly in #66. Hooray!
User avatar
Charles
 
Posts: 31
Joined: Wed Feb 15, 2012 12:39 pm


Return to Moai SDK

Who is online

Users browsing this forum: No registered users and 0 guests

x