Retina Display Doubt

Hello Community, I'll make a game just for iPhone and iPod Touch (no Android, no iPad); I'll use the Retina Display resolution for iPhone 4 and iPod Touch 4, and I was wonder if I can do it just scaling the images with "letterbox", making higher images (640X960) scale down (320X480) without using the suffix @2x.

I'm not sure which way you mean: do you want to scale lower res graphics UP to use on the retina display, or do you want to scale high res graphics DOWN for use on non-retina displays? If it's the latter, I would recommend using the @2x convention. In my experience with 3G and 3GS phones, using graphics meant for the 4/4S models takes a substantial hit on performance.

If you want to scale lower res graphics up to use on retina displays they will look blurry, but it is possible.

Its about memory usage.

If your app is small it may not matter, but the 3G and 3Gs and older devices only have 256M of memory and of course you don't get all of that since the Operating System and such consumes part of it. A 200x200 pixel image is 160K of memory. A 100x100 is 40K of memory. 100 objects at 200x200 is 16MB of memory. 100 objects at 100x100 is 4mb. Your full screen backgrounds are 2.4M in memory at 640x960 as opposed to 0.6m for a 320x480... (these are uncompressed in-memory sizes, not the compressed disk versions...)

So it doesn't take much if you're using Retina/HD graphics to blow out your available memory.

Regardless of resize up or down, it takes CPU speed. So performance is important to your app, providing both sizes and letting display.newImageRect() pick the right one will be the most efficient on the device.

views:1486 update:2012/1/13 9:04:04
corona forums © 2003-2011