0

I am new in iOS

my question is we can take different sizes of images for app icon that support iPhone and iPad pick that images default as per screen resolutions.

same thing how to apply for other images in app. also is it necessary take every image with different sizes or resolutions?

if it is necessary then what is the best way for that?

appreciate for help.

Vinod Jadhav
  • 1,055
  • 1
  • 15
  • 37

1 Answers1

2
  • For Other Images:

Let’s assume our image is supposed to be called “name”. We need to supply four image resources. The iPhone resources are supposed to have the ~iphone suffix and accordingly the iPad resources need the ~ipad suffix and the @2x for the retina display is in between the name and the suffix. So this is what we get:

•   name~iphone.png
•   name@2x~iphone.png
•   name~ipad.png
•   name@2x~ipad.png
•   name-568h@2x~iphone.png (iPhone 5)

It is important that the suffix is all lowercase. With this naming convention there is no need to do that any more because

[UIImage imageNamed:@"name.png"];

handles the loading of all different image sizes.

For more info see this & this.

  • For App Icon:

You should use Asset Catalog.

For more info see Link1, Link2 & Link3

  • For Lunch Images:

see this.

Community
  • 1
  • 1
Yasika Patel
  • 6,356
  • 3
  • 19
  • 21