i’m building my game for the iphone 4g, their is substantial lag and touch delays. on the 4g version that isn’t appearing on my iphone touch2G.
i’m building for os 4.1, does anyone know why this would be happening.
i’m building my game for the iphone 4g, their is substantial lag and touch delays. on the 4g version that isn’t appearing on my iphone touch2G.
i’m building for os 4.1, does anyone know why this would be happening.
whats your current FPS?
targeting the iphone4 / 4th gen / ipad leads to significant restrictions on the fillrate (the touch 2G is significantly ahead on the amount of fullscreen redraws possible) which if forgotten lead to total fps breakins etc
I had problems on 4G at first too, but using more optimized shaders helped a lot.
On that matter: ensure to either not build for OpenGL ES 2.0 or disable it in the generated xcode project through the define unless you explicitely need opengl es 2.0
hmmm…i’ll try the building without opengl, and optimizing our shaders.
the frame rate is about 15 frames a second and touches as far as i can tell are waiting1-2 frames to be received
well it seems the main culprit behind my lag was because i had the target setting to the highest available resolution. is their a way of taking advantage of the iphone 4g’s max resolution without such a performance hit? it’s a shame to have that their but the phone not be able to handle it.
Yes, optimize your game for the 4x as high number of pixels.
If the resolution makes such a difference it might very well be caused by fillrate. in that case you will need to optimize the shaders and use blending but especially alpha only where crucial (which also means that using alpha to hide parts where you could just modelled it is not the way to go).
the iphone 4 can redraw its full screen pixel amount about 3-4 times per frame to remain in the fluent area. using alpha - cutout - particle or generally any other blending shader causes each draw on screen to be a redraw of pixels ie filling up the fillrate
without knowing more though its not possible to give more specific hints but look at the optimization thread in relation to ipad thats rather active, should give you an idea as the same stuff applies to iphone 4 too which has the same graphics chip as ipad and 3GS devices
thanks dreamora, i’ll look at that right away