I have a fairly simple splash screen with a background image (aspect fill) and some text and stuff laid out with auto layout.
The same thing occurs building with Xcode 11.7 or Xcode 12 as long as you target an iOS 14 device or simulator.
If there is an image in the Launch Screen storyboard, the launch screen appears pure black with and none of the components appear on the screen. If I rename the image source to an invalid one, all components appear except the image.
I have tried moving the image out of the asset catalog with no luck. I have tried using the new iOS 14 splash screen info.plist options but can't replicate the design I need to, plus the docs say that storyboard launch screens will still be supported so I can't figure this out.
Anyone else seen this and had any luck fixing it? I have tried everything I can think of! The only other similar question on stack is here but is vague and could be unrelated
Here's how I was able to resolve this for others who can't use the new launch screen API due to design restrictions:
Build using Xcode 11
Convert any images used in the Launch screen to PNGs
Rename the image assets in the catalog and update the references in the Storyboard as well (this is important!)
Clear the splash screen cache by calling this at the beginning
of didFinishLaunching
(only in debug mode!):
@try {
[[NSFileManager defaultManager] removeItemAtPath:[NSHomeDirectory() stringByAppendingString:@"/Library/SplashBoard"] error:&error];
} @catch (NSException *exception) {
NSLog(@"Failed to delete launch screen cache: %@", error);
}
after that my splash screen works on iOS 14 and prior as expected.