What's wrong with my asset catalog containing launch images?
I’m not using storyboards here, for reasons that would be a distraction to get into. I’m instead trying to add four launch images to an asset catalog:
My app doesn’t support iPads or 3.5-inch iPhones, so these should be sufficient. Is that fine or do I need landscape as well?
Here are the properties of each of the images:
Here’s the same information in textual form:
filename: LaunchImage.launchimage children: filename: 5.5.png idiom: iphone subtype: 736h scale: 3x orientation: portrait extent: full-screen minimum-system-version: 8.0 image: height: 2208 width: 1242 filename: 4.7.png idiom: iphone subtype: 667h scale: 2x orientation: portrait extent: full-screen minimum-system-version: 8.0 image: height: 1334 width: 750 filename: 3.5-inch, 2x-1.png idiom: iphone scale: 2x orientation: portrait extent: full-screen minimum-system-version: 7.0 image: height: 960 width: 640 filename: 4.png idiom: iphone subtype: retina4 scale: 2x orientation: portrait extent: full-screen minimum-system-version: 7.0 image: height: 1136 width: 640
Here’s how my app is configured:
When I run the app on the iPhone 7 Plus, I see the 4.7-inch launch image. Why is this happening, and how do I fix it?
I tried using plain PNG files without putting them in an asset catalog, but that doesn’t work, either, as discussed in this separate question.
Note that unlike other questions asking about this:
I’m not using xibs or storyboards, for reasons that would be a distraction to get into here.
I’m using PNG files wrapped in an asset catalog, as opposed to plain PNG files in the top-level directory.
I support only iOS 10 and above, which means I don’t support 3.5-inch phones.
I don’t support iPads.
I’m using Xcode 8.3 and running iOS 10.3 on my phone.
- Use vector artwork for iOS launch image in asset catalog?
- iOS8 icons sizes and names for icons and launch image
- How to add Images for different screen size from Assets.xcassets in Xcode 8?
- iOS how to set app icon and launch images
- Launch Image not showing up in iOS application (using Images.xcassets)
- LaunchImage in Images.xcassets with Launchscreen.xib
2 Solutions Collect From Internet About “What's wrong with my asset catalog containing launch images?”
I had an issue very similar to this recently, where my 4.7″ iPhones were unable to load the 667h launch image and fell back to the size it could, being the 538h. Since iOS uses the presence of static launch images as one of its determinations for what resolution to display the app at, the app ended up coming out all blown up in resolution.
It doesn’t sound like you’re hitting that latter consequence, but I can share my fix: re-evaluate the color space you used to export those images and try exporting them again. I wasn’t able to pin down the exact reason why the images were an issue for the platform, but re-exporting and cleaning helped. In addition to the color space, did you perhaps use a Save for Web option? I also found that affected things for us.
Have you tried cleaning the project and the build folder, deleting derived data, removing the app from the device and restarting Xcode?
Might sound like a silly suggestion, but this has fixed so many things for me in the past.
- Protocol func returning Self
- Swift Language Multicast Delegate
- signInSilently() generates an error code=-4
- How to send in-app announcements to people using my iOS app?
- iphone imagepickerController picking video from photo library
- Reconnect a CBPeripheral faster
- IBM Worklight 6.1 – Failed re-generating the iPhone native folder
- Show posts from the users you are following – swift
- Make Xcode highlight selected symbol more
- How do I change my iPhone App binary filename
- UIPageViewController Gesture recognizers
- iPhone Could Not Support Development
- Does hiding “Legal” in MKMapView result in an App Store rejection?
- Change GMSMapView default map background color in iOS
- iOS7: background task (“myapp” has active assertions beyond permitted time)