Image sizes required to support all iPhone devices

2019-09-07 02:01发布

What all splash screen images do we required to create an iOS application? I want to give support all the devices which supports iOS8. Trying to find out working of Images.xcassates and how to add splash images.

I want to support iPhone 4, iPhone 5/5s/5c, iPhone 6/6+, iPad.

What is the naming convention required to set LaunchImage? I just saw 1x, 2x, Retina 4 2x, and 3x in xcassates. But not getting what file names it required.

Like for non retina and and retina we simply twice non retina image for retina and name it like xxx@2x.png for retina and xxx.png for non retina.

Not getting apple document regarding this.

Thank you.

3条回答
兄弟一词,经得起流年.
2楼-- · 2019-09-07 02:24

Now in New versions Image name for splash is not required. you can just drag and drop images in "LaunchImage" image asset. Please check below screenshot.

On right side you can see it's required image size in Expected Size : 1242x2208 pixels.

just drag same size image there and you are done.

enter image description here

Maybe this will help you.

查看更多
男人必须洒脱
3楼-- · 2019-09-07 02:31

There is a default black LaunchImage in xcassets, you jsut have to dragndrop your images into corresponding canvas. XCode will automatically name those images for you.

Note that in xcassets you can choose to see canvas for only iOS 8, iOS 7 or more, iOS 6 or more, etc.

查看更多
爷的心禁止访问
4楼-- · 2019-09-07 02:50

Using image.xcassets, you do not need to follow naming convention. You just drag and drop the image to placeholder inside the image.xcassets. Xcode will handle that for you.

To support multiple device, you can easily match with the naming below the placeholder. eg. iPhone Portrait iOS7,8: 2x: iPhone4, Retina 4: iPhone5/5s/5c

For iPhone 6/6+, you can enable iOS8.0 iPhone checkbox on the right panel.

You can also see the expected sizing on the right panel.

the checkbox and the expected size

查看更多
登录 后发表回答