Pregunta

I am building a small game for iOS on Flash CS6 and I want to target both iPad and iPhone resolutions, also supporting retina display if possible. I've played with the movie properties and the Air for iOS settings, but I am still in confusion about the screen resolutions. I want to make a HD (retina-enabled) game, and I want to target the non-retina models too. Which resolution should I use? (I'll be having only landscape) Should I go with 2048x1536 (iPad Retina), 1024x768 (iPad non-retina), 960x640 (iPhone/iPod touch retina), or 480x320 pixels (iPhone/iPod touch non-retina)? I've set the resolution to High in Air for iOS settings, left the default resolution (960x640) unchanged, but when I tested it on iPad 3, the resolution wasn't HD, even though my graphics were vector (made in Flash). There was also background color visible around the corners, compensating for the aspect ratio difference of iPhone and iPad. Why can be the App rendering in non-retina resolution even though I've checked it at the settings for iOS? And more importantly, what is the best approach for targeting both screen resolutions in a single app?

Thanks, Can.

¿Fue útil?

Solución

Despite iOS being a resolution dependent OS, stage resolution doesn't matter. It will look the same if the stage resolution was 240x160 or 1920x1280. The device will render the game to it's native resolution. This is why you need to set the resolution in the publish settings: so that flash knows to add support for those resolutions for iOS. Setting the stage to 960x640 should be fine for the iPhone. When it publishes for iPad on the other hand, it will be built to it's native screen resolution, but because the iPhone and iPad have different aspect ratios, the iPad will have more space on the side. Since the game will be in landscape mode, it should be ok to simply put to thick black rectangles on the top and bottom of the stage.

As for the new iPad resolution, Flash isn't powerful enough to support that resolution, it will export to the standard iPad resolution of 1024x768 even if the resolution is set to high in the publish settings.

So pick the stage resolution based off of what device you favor, if you want the app to look best on the iPad's format, go for 1024x768, but the iPhone will have extra space on the sides in landscape mode. The same goes for the iPhone resolution I explained earlier. Although, if you'd like to fully support both, you can try many methods used to position GUI elements on the vast sea of Android Screens based off the Capabilities.screenResolutionX and Capabilities.ScreenResolutionY methods in flash.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top