Skip to main content
Inspiring
Aug 25, 2014 6:56 PM UTC
Question

iPhone 4 and iPhone 5 - which stage size?

I'm developing an AIR app for iPhone 4 and 5. The app is centered around a video which I have exported in two versions, a 960x640 version for iPhone 4 and an 1136x640 version for iPhone 5.

Ideally, I would like to just detect whether I'm on an iPhone 4 or 5 and then add the right video and play it. However, I don't know how thisis affected by the stage size, which has to be one resolution or the other. I assume that if the stage size is set to 960x640, it will scale up on an iPhone 5 - and scale down on an iPhone 4 if set to 1136x640.

In my situation, how would you solve this problem? Is there a way to prevent scaling and just placing the right video on the stage at 0,0?

This topic is closed to new replies. Start a new post to keep the conversation going.

14 replies

Known Participant
Sep 20, 2014 9:03 PM UTC

Thanks Colin, I was missing the h in the Default-568h@2x.png.  I have changed the resolution to high (I was hoping not to have to do this, as in the past it worked fine for previous apps on high res ipad devices).  It is compiling now so hopefully it works properly. 

Cheers,

Justin

Translate
Known Participant
Sep 20, 2014 9:07 PM UTC

It worked.....you are awesome.

Justin

Translate
Colin Holgate
Inspiring
Sep 20, 2014 9:33 PM UTC

You can disable the iPad 3 Retina with this entry in the XML:

<requestedDisplayResolution excludeDevices="iPad3">high</requestedDisplayResolution>

That way it's Retina for the other devices, but you don't have to suffer the poor performance of the iPad 3 Retina.

Translate
Inspiring
Aug 28, 2014 6:19 PM UTC

Thanks. And just to be clear: If I set scaleMode to NO_SCALE, and I play a video of 1136 px width in an app with 960 px stage width, it will show up as fullscreen on iPhone 5?

Translate
Colin Holgate
Inspiring
Aug 28, 2014 6:29 PM UTC

You will need to look at the stage width and if it's 1136, play the 1136 wide video. If it's 960, play the 960 video. In both cases the video would be a 0,0.

Don't forget to include the Default-568h@2x.png splash screen, without that the iPhone 5 will act like a 960x640 screen.

Translate