I’m developing on an iPhone 3G (no pitchforks needed, I know it’s a ‘dead platform’). However, I’m curious as to the frame time that’s being reported in the profiler. It appears that if I disable absolutely everything, and just have a single full-screen quad it doesn’t even run at 60fps ( 16.6ms). The minimum is 16.6ms but the max is always around 33ms, with the average almost always exactly 25ms. I’ve set the kFPS to 60.0 and have tried ALL different timing methods.
I’m wondering if there’s some kind of timing granularity where it only goes in frame increments (increments of 16.6ms), thus giving me 16.6ms and then 33.3ms and averaging out to 25ms. Is vsync forced on? Has anyone run into this issue?
I would definitely like to hit 60fps in my game and I can’t seem to do that if a full-screen quad can’t even run at 60fps. Looking at these forums, it appears people have hit 60 on iPhone 3G in the past; is it just the new iOS releases slowing it down? Is it that Unity’s targeting 3GS and above? Any insight would be helpful.
Yes, I have changed it to 60. I’m using the RageSpline Basic shader (no lighting), just alpha blending. It’s one of the most basic shaders you can have. There’s no alpha on the quad. Yes it’s a quad, it’s not some crazy ragespline shape. Here’s the stats:
There is no texture, it’s just using vertices to colour it. I disabled everything on the phone (location / wifi / etc.) I also put the phone into airplane mode, still the same results. It’s gotta be a timing issue. I’m going through all the timers again and put the kFPS to 100.0, even though I see it hard caps at 60.0 in most places. Maybe I’ll try removing those hard caps as well… very disappointed :(.
I do appreciate you trying to help me out though. Since you’re responding so fast, wanna hop on IRC? We can post back any solutions we find here.
CONFIRMED this bug in Unity. Landscape rendering modes on iOS builds drop the frame rate considerably. Submitted a bug to Unity about this. Big thanks for GabrielR who spent his entire day helping me track this down.
I have not tested a work-around, but I assume you could probably set your game to Portrait and rotate your scenes 90 degrees.
This is bug in old iOS firmwares. Apple fixed that with some 4.x release. Currently you might try to workaround it by not using “native” autorotation mechanism.
It’s a shame unity doesn’t use the old style automatically, by abstracting native autorotation. Thats something that can really help avoid problems like this. I guess you don’t have resources available to do it at the moment.