iPhone optimization

Get help using Construct 2

Post » Sat Jan 14, 2012 5:07 pm

My game runs at a steady 60fps on the pc. But on my iphone it's around 47. How would one optimize the game for better performance on handheld devices? Any tips?

I've also heard that if the canvas is at lower dimensions than the iPhone screen, then it will be scaled to fit, which will have a huge impact on performance. Is this true?
And would I in that case be recomended to develop my game in 960x640 which is the resolution of the iPhone 4+, rather than 480x320?joelsandberg2012-01-14 17:09:16
B
4
Posts: 16
Reputation: 482

Post » Sat Jan 14, 2012 5:18 pm

I'm not sure about most of your questions, but you might want to try Appmobi. They claim using it significantly increases rendering speed, physics calculations and has multi channel audio. I haven't used it though, so I'm not sure about how easy it is to use.Arima2012-01-14 17:18:24
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Sat Jan 14, 2012 5:20 pm

Yes you are correct(I think), the larger the canvas then FPS will drop a little. Also if your game heavily relies on physics then the FPS will drop.

Its also to do with graphics, If you have graphics of a Higher DPI then if you have a every tick event and are manipulating that object, then its likely to be quite expensive in VRAM.
B
29
S
12
G
7
Posts: 740
Reputation: 7,849

Post » Sat Jan 14, 2012 5:37 pm

[QUOTE=Arima] I'm not sure about most of your questions, but you might want to try Appmobi. They claim using it significantly increases rendering speed, physics calculations and has multi channel audio. I haven't used it though, so I'm not sure about how easy it is to use.[/QUOTE]Appmobi seams interresting, however I don't want to spend loads of money on it, and it seems to be a bit complicated.

Construct 2 is fairly easy to understand. Isn't there any way the developers will improve the performance? I mean, if Appmobi does it 5(?) times better than usual html5-apps, why can't construct 2?

[QUOTE=smitchell] Yes you are correct(I think), the larger the canvas then FPS will drop a little. Also if your game heavily relies on physics then the FPS will drop.

Its also to do with graphics, If you have graphics of a Higher DPI then if you have a every tick event and are manipulating that object, then its likely to be quite expensive in VRAM.[/QUOTE] Then I'll try using a resolution of 960x640.
I always try to optimize the graphics also, but how does one optimize the DPI?
And I know performing an action every tick isn't the smartest, but it seems to me it is the only way to go if you want f.e an object to constantly move in one direction? Or am I wrong?joelsandberg2012-01-14 17:37:51
B
4
Posts: 16
Reputation: 482

Post » Sat Jan 14, 2012 5:39 pm

A behavior could do that as well, like the bullet behavior.
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Sat Jan 14, 2012 5:45 pm

Ah I see! How is a bullet behavior compared to the Every Tick-event in terms of performance?
B
4
Posts: 16
Reputation: 482

Post » Sat Jan 14, 2012 5:50 pm

Do a test capx, Have a layout moving a sprite every tick.
Then have another using the bullet behavior.
Add a text box on each layout and have this event to get the FPS:

System.everyTick
     ->Text.setText("FPS :" & FPS)

and as for the DPI, its dependent on the game its self. You need to play around with values.

what DPI are you currently using for your graphics?

The iphone 4 and 4s aswell as ipad two use a DPI of 326 for there retina display. <- Moving a sprite every tick with a DPI of this should be pretty intense!!
B
29
S
12
G
7
Posts: 740
Reputation: 7,849

Post » Sat Jan 14, 2012 5:59 pm

Always remember that phones don't have big processors
like pc and 47 fps is very good for a phone
(mine just do 20 fps)
B
35
S
16
G
16
Posts: 2,222
Reputation: 16,589

Post » Sat Jan 14, 2012 6:01 pm

I don't really know what dpi I'm using, 72 I guess ?
But I can basically turn the dpi down to 1, or can't I?

I'll try out the bullet behavior!
B
4
Posts: 16
Reputation: 482

Post » Sat Jan 14, 2012 6:06 pm

DPI means Dots Per Inch. The default in photoshop is 72. Its what determines whats HD or not really. If the DPI is higher the graphics are crisper. If the DPI is quite high then if you zoom in to the image/graphic then you wont really see pixels unless you zoom in to far.

But to have a HD game you have to pay the price in load up time and VRAM
B
29
S
12
G
7
Posts: 740
Reputation: 7,849

Next

Return to How do I....?

Who is online

Users browsing this forum: h1k3, Unconnected and 0 guests