4

I have set the launch images in an asset catalog (LaunchImage), which I've also set in the target's "General" tab in Xcode. The default LaunchScreen file was being shown when running the app, but I read this post and I did what it is said there: to left empty the Launch Screen File parameter both in "General" tab and in .plist

But now, instead of showing the appropiate launch image from catalog or the default one, I'm showing a black screen...

I'm supporting only iPhone, and iOS 7, 8 & 9.

What could I be missing?

Thanks

EDIT: could this be because of incorrect image sizes? For example, for the iPhone Portrait Retina HD 5.5 I have a file of size 1242 x 2208 and name launch_iPhone6Plus-Portrait@3x.png, is that correct?

EDIT 2: This is what I have in the target's "General" tab. target settings

Community
  • 1
  • 1
AppsDev
  • 12,319
  • 23
  • 93
  • 186
  • Use image assets for Launch images in that case. Just drop two images of size 2x(640 x 960) and Retina 4(640 x 1136). Works fine for me. – NightFury Dec 15 '15 at 11:04
  • @iAnum yes, that's what I'm trying, to take the launch images from the image assets... but it does not work – AppsDev Dec 15 '15 at 11:08
  • @AppsDev please check this answer : http://stackoverflow.com/questions/34043541/xcode-7-launch-screen-images-dont-load-properly/34043799#34043799 – Maulik Patel Dec 15 '15 at 11:51

2 Answers2

16

Well what I've noticed that when you create a new project by default you will get LaunchScreen.storyboard as you Launch Screen Image.

But if you don't want to use LaunchScreen.storyboard then what you do is remove LaunchScreen.storyboard and tap on Use Asset Catalog.

But by default it will give you Brand Asset instead of Launch Image in Xcode Version 7.1.1.

Now click on the arrow besides Brand Asses/Launch Image. Xcode will navigate you to Assets.xcasets folder.

Now click on + below to add App Icons & Launch Images.

From there you need to select New iOS Launch Image. enter image description here

This is how your LaunchImage should be visible. enter image description here

Now add the images according to size specified in the Apple Documentation. You can also get Launch Image Size from this url: LaunchImageSize

Now go application>Targets>General and in Launch Images Source select LaunchImage. enter image description here

Here is the image with LaunchImage added in Assets.xcassets. enter image description here

Simulator Image on launching App. enter image description here

Hope it helps in solving your problem.

Community
  • 1
  • 1
Dhaivat Vyas
  • 2,926
  • 1
  • 16
  • 26
  • Thank you, this really helped me. – eugen Mar 12 '16 at 10:23
  • I tried this, but it didn't work: http://stackoverflow.com/questions/43168145/whats-wrong-with-my-launch-images Any idea why? Thanks very much. – Kartick Vaddadi Apr 04 '17 at 06:35
  • I just figured this out. My launch image was not showing up, I get a white screen when launching on a device (iPhone 6, 7+) or testFlight. Fix: Renamed "Landing_screen.png" to just "Landing_screen" removing .png part. The image icon in Xcode changed to white icon and in the launch screen storyboard the image appears as a question mark now. The Launch image now appears and not the white screen. – Brian Bird Apr 24 '17 at 16:17
0

Have you changed the setting for your project so that it points to the Asset Catalog as the source for your Launch Image?

enter image description here

sanjeet
  • 1,539
  • 15
  • 37