- Home /
Force *only* iPhone 4 to 480x320 resolution
Hi--I've got a mobile game in development, and it runs smooth as butter on the iPhone 5; on the iPhone 4, it stutters a fair amount. And it's a very precise action game, so any stuttering ruins it.
Therefore, I want to force the iPhone 4 to half-resolution (matching the iPhone 3G) but keep using the retina display on the iPhone 5.
If I set the target resolution to 320 under iOS in Player Settings, that spoils it for the iPhone 5. Or so I would think--actually, when I set it to 320, then build it and try it on my iPhone 4, it still runs at 960x640.
So, two questions:
Why doesn't the Target Resolution setting do anything? Is there a setting I have to tweak in Xcode? (Here I will be honest and say that I look at the range of settings in Xcode and feel a strong urge to close the laptop and go outside.)
How can I force a specific resolution on iPhone 4 only? Detecting iPhone 4 in script (via iPhoneSettings.generation) and then setting resolution with Screen.SetResolution only produces a black screen--I understand SetResolution isn't really supposed to work with iOS. This answer looks promising: http://answers.unity3d.com/questions/271770/different-resolutions-on-iphone-4-and-4s.html -- but Unity appears not to generate AppController.mm for me, and the closest looking thing, UnityAppController.mm, doesn't contain any code resembling the code that this answer suggests I modify. (And to be honest again, the code it does contain is a little over my head.)
Would be majorly grateful for any assistance. Thanks!
Your answer
Follow this Question
Related Questions
apple rejected app due to iphone & iPad resolution mismatch 1 Answer
2d iOS game: different resolutions question. 1 Answer
iOS Target Resolution doesn't seem to affect resolution 0 Answers
How do you account for iPhoneSettings.generation not working in the Editor? 2 Answers
Unity Screen.SetResolution gives me black screen on iPhone 4S 1 Answer