Performance problems on iPad Retina

Ok so I’m just starting a new project and thought hey, I’m not too far into it lets change it to use the new graphics 2.0.

There weren’t many changes and I did it step by step to make sure I got everything working as was with v1, the main changes were the reference points and changed them to anchor points. 

All went well and it worked well on my new iPhone 5S and iPad Mini (both running 7.02) so I thought lets load it up on my iPad 3 (running 7.02) since I have retina graphics, looks good except there is a definite lag when I am dragging things around the screen and the transitions were slow or skipping.

I thought maybe I missed something, so I undid the changes one by one and tried each version on my iPad 3, it only became smooth when I didn’t use graphics 2.0.

I’d like to upload the files but there are a quite a few and I don’t really have time to make a demo project but I thought I would bring it to the attention of the masses and the management, to see if anybody else sees the same problem.

Hmmm.

I just tested a Graphics 2.0 build on my iPad 3 (iOS 7.0.2) and my physics based app with Partice Candy and transitions is behaving as expected as far as I can see…

I can confirm this issue on iphone4.

It´s 100% the same code except for this.

display.setDefault( "background", 0.5, 0.2, 0.1, 0.5 ) display.setDefault( "lineColor", 0, 0, 0, 0.1) display.setDefault( "fillColor", 0, 0, 0)

I am using Raycasting with 200 lines on screen but I just call it once in createScene event.

Build using graphics 2.0: <28 fps

old engine: 50-60 fps

Do you have a retina sized background screen?

I just took the background screen out and it runs smoothly, not sure wether that’s because its a big asset (2048x1536) or it’s part of the problem.

Obviously I need my background screen so it’s not a solution :stuck_out_tongue:

I am still having issues with my app when built for device using G2.0 builds… 

@cublah… I’ll try remove any large back ground images… cause I too have a fairly large one… I wonder if we have a texture memory issue… which we cant see cause texturememory reporting is broken in g2.0 builds? well mine aint reporting memory use anyway… it just reports zero

Just removed my background image… a 1136x880 image… and I got a 2 fold increase in framerate… ie… I am now getting about 20fps… was getting <10fps… in an app that runs at 60fps in sim and on device when built with G1.0 builds…

Like I said, I cant see my texture memory used cause that function aint working anymore… 

This is not right!

@ingemar… would you mind adding a large background image to your app thats working fine with G2.0 …and test it… see if you get a severe drop in frame rate? 

Would really appreciate you taking the time

Cheers

Strange. I use a huge graphic on the iPad Retina.

I use background images with bleed zones to make sure it covers all kinds of screen sizes (using letterbox mode).

This makes my iPad Retina background graphic 2440 × 1680 pixels, and I have had no problems with it on the iPad Retina.

The sizes are:

610 x 420 (normal)

1220 x 840 (@2x)

2440 x 1680 (@2x~ipad)

with the following in config.lua:

imageSuffix = { ["@2x"] = 1.4, ["@2x~ipad"] = 3.4 }

I don’t use ray-casting and there’s not a lot of action in the scene at any one time. At most there are about 10-20 objects active in each frame and on average there are less than 10.

I only use physics and sprite-animation in the app.

see my latest  comment on other thread

http://forums.coronalabs.com/topic/40370-frame-rate-when-build-for-xcode-sim-or-device/

Maybe we can continue on one of these threads… Im jumping between both now :slight_smile:

@richard770

We’re still tuning, but I wanted to check back in and see if you had a chance to test your app with the latest changes for performance. We have made a few optimizations.

Hey @Bryan

See

http://forums.coronalabs.com/topic/40370-frame-rate-when-build-for-xcode-sim-or-device/page-6

Cheers

Hmmm.

I just tested a Graphics 2.0 build on my iPad 3 (iOS 7.0.2) and my physics based app with Partice Candy and transitions is behaving as expected as far as I can see…

I can confirm this issue on iphone4.

It´s 100% the same code except for this.

display.setDefault( "background", 0.5, 0.2, 0.1, 0.5 ) display.setDefault( "lineColor", 0, 0, 0, 0.1) display.setDefault( "fillColor", 0, 0, 0)

I am using Raycasting with 200 lines on screen but I just call it once in createScene event.

Build using graphics 2.0: <28 fps

old engine: 50-60 fps

Do you have a retina sized background screen?

I just took the background screen out and it runs smoothly, not sure wether that’s because its a big asset (2048x1536) or it’s part of the problem.

Obviously I need my background screen so it’s not a solution :stuck_out_tongue:

I am still having issues with my app when built for device using G2.0 builds… 

@cublah… I’ll try remove any large back ground images… cause I too have a fairly large one… I wonder if we have a texture memory issue… which we cant see cause texturememory reporting is broken in g2.0 builds? well mine aint reporting memory use anyway… it just reports zero

Just removed my background image… a 1136x880 image… and I got a 2 fold increase in framerate… ie… I am now getting about 20fps… was getting <10fps… in an app that runs at 60fps in sim and on device when built with G1.0 builds…

Like I said, I cant see my texture memory used cause that function aint working anymore… 

This is not right!

@ingemar… would you mind adding a large background image to your app thats working fine with G2.0 …and test it… see if you get a severe drop in frame rate? 

Would really appreciate you taking the time

Cheers

Strange. I use a huge graphic on the iPad Retina.

I use background images with bleed zones to make sure it covers all kinds of screen sizes (using letterbox mode).

This makes my iPad Retina background graphic 2440 × 1680 pixels, and I have had no problems with it on the iPad Retina.

The sizes are:

610 x 420 (normal)

1220 x 840 (@2x)

2440 x 1680 (@2x~ipad)

with the following in config.lua:

imageSuffix = { ["@2x"] = 1.4, ["@2x~ipad"] = 3.4 }

I don’t use ray-casting and there’s not a lot of action in the scene at any one time. At most there are about 10-20 objects active in each frame and on average there are less than 10.

I only use physics and sprite-animation in the app.

see my latest  comment on other thread

http://forums.coronalabs.com/topic/40370-frame-rate-when-build-for-xcode-sim-or-device/

Maybe we can continue on one of these threads… Im jumping between both now :slight_smile:

@richard770

We’re still tuning, but I wanted to check back in and see if you had a chance to test your app with the latest changes for performance. We have made a few optimizations.