Xcode Image Asset By Device - ios

My question relates to creating a custom image asset for iPad Pro. It is my understanding that the correct image from an image asset set in Xcode is picked based on the type of device in the following way:
iPhone:
1x: iPhones older than iPhone 4
2x: iPhone 4/4s, 5/5s, 6/6s
3x: iPhone 6/6s Plus
iPad:
1x: non-retina iPads
2x: retina iPads (including iPad mini)
If this understanding is incorrect, please let me know. But if it is correct, how do I make a custom image set for iPad Pro? The images I made for the regular-size retina iPad would be too small to fit on the iPad Pro and there is no 3x option for an iPad image set.

Related

Is there any need to use #1x images if app is creating above iPhone 4+ devices?

I am creating my app for only iPhone 5, iPhone 6 and iPhone 6+.
I got some info as mentioned below:-
1- Normal device which terms to 1 pixel = 1 point #1x (Older iPhone and iPad devices)
2- Retina device which terms to 4 pixels(2 x 2) = 1 point #2x (iPhone 4+)
3- Retina iPhone6 and iPad which terms to 9 pixels (3 x 3) = 1 point #3x (iPhone6+)
Please clarify that is there any need to add #1x images in Images.xcassets?
For iPad 2 you need 1x resolution pics. So for that situation you need 1x images in your image assets but in case you are not officially supporting iPad and iPhones above 4 then you don't need those. But an iPhone only app runs on iPad too so you need to include the images in 1x resolution. In case you are supporting iOS 10 + only then in that case you don't need 1x images as iPad 2 does not support iOS 10.

iOS #2x images conflicting

I've a little confusion and facing a little problem regarding #2x images in iOS as according to Human Interface Guidelines HIG, the #2x For iPhone 6: 750 x 1334 (#2x) for portrait but same #2x for iPhone 4S has size of 640x1136.
HIG
When I placed #2x image named as MyTestImage#2x.png of size 750 x 1134, it was fine for iPhone 6 but not for iPhone 4S, but if I put MyTestImage#2x.png of size 640x1136 then its fine for iPhone 4S but not for iPhone 6.
I also placed 640x1136 as Retina 4 2x named as MyTestImage-568h#2x.png but its also not working for me.
Whats I'm conflicting? What should be the actual image sizes of #2x for iPhone 4S and iPhone 6 if I talk about a full screen image.
And also what should be the correct retina display image size.
EDIT 1:
My question is different as I want to know the difference between #2x and -568h#2x retina display regarding both screens. Also, any optimal solution for this which can avoid image redundancies.

Image Sizes for Supporting iPhone 4S,5,5C/S,6 and 6+

I want to support a variety of devices from iPhone 4S to iPhone 6+. Previously, when adding supporting for iPhone 5, we followed the following steps.
Add the launch Default-568h#2x.png
Use the same #2x images (640x960) which are resized automatically for iPhone 5.
Now, iPhone 6 and 6+ are introduced with varying sizes and it is written on most blogs that we will use #2x for iPhone 6 and #3x identifier for iPhone 6+. It is also written that:
iPhone 6+ (#3x) images will have resolution of 1242x2208 (I am using portrait mode), and it is automatically downsized.
iPhone 6 will use #2x images.However,I am not sure what the size of these images should be. Should they be 640x960 or 640x1136 or 750 x 1334. In case of using the first two sizes, won't the images be distorted?
I think what you are after is detailed in the HIG under "Icon and Image Sizes"
https://developer.apple.com/library/ios/documentation/userexperience/conceptual/MobileHIG/IconMatrix.html#//apple_ref/doc/uid/TP40006556-CH27-SW1

How to upgrade iPhone 5 graphics to iPad Retina?

I have an iPhone 5 optimized app and I would like to upgrade its graphics for iPad Retina.
How can this be accomplished?
Do I have to double the size of every graphic element I currently have from image#2x to image#4x?
If your app is already optimised for the iPhone 5 Retina screen (as in having #2x) image files which are double size graphics for your image assets then you shouldn't need to do anything else for the iPad Retina Screen apart from creating iPad Retina Splash Screens (if necessary).

iPad retina stretches non-retina images in Cocos2d

I have a iPad app built with SDK 5.1 (Xcode 4.4). The app is a non-retina app. On iPad 1 and 2 the images are scaled properly. On the new iPad (3rd generation) all the images get scaled up. This behaviour is kind of expected, but undesired in my situation. How do I prevent the images from being scaled up?
Since you are building for both Non-Retina and Retina devices you should include both versions of all images. The Retina images should be double in size of the screen resolution and should have the #2x.png (or jpg) suffix. Example: Background-Image#2x.png

Resources