I am using Xcode 6.1 to create a app supporting iOS 6 and later.
.In target's "App Icons and Launch Images", I set the Launch Images Source as "Use Asset Catalog" and Launch Screen File to "LaunchScreen".
In Images.xcassets which created by Xcode, I fill in every box for "LaunchImage", but there's always a warning message:
Retina 4-inch Support. Applications using Launch Screen Files and
targeting iOS 7.1 and earlier need to also include a Launch Image in
an Asset Catalog.
I created another Image Set named as "Default" and fill in the "Retina 4 2x" box with expected image. But the warning message still there.
Any hint to clear this warning? Thanks.
I ran into the exact same problem this morning. Here's how I fixed it.
Select your Target in the project navigator. Under the General tab, you should see the section for App Icons and Launch Images. Where you see Launch Images Source, click 'Use Asset Catalog'.
You will then see Migrate launch images to an asset catalog dialogue. Click 'Migrate'.
Make sure that your Launch Images Source on the previous screen points to the right image set in your asset catalog. In your case, you would set it to 'Default'.
That should take care of the warning.
Related
I have a very silly question, my xcode project doesn't have setting for Launch Image Source , I have already added my splash screen image to Images.xcassets -> LaunchImage , but in my project target General -> App Icon and Launch Images doesn't have setting for Launch Image Source
I was facing the same issue which I solved this way:
Select your target in the project navigator and find the Build Settings section
Search for the Asset Catalog Compiler options
Go to the Asset Catalog Launch Image Set Name option and set its value to the name of the iOS launch image you created. If you went with the default name, then this value would simply be LaunchImage.
If the new launch screens do not show, it might help to delete your app and install it again.
Also make sure the Launch Screen File option in your target's General Settings is blank.
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.
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.
This is how your LaunchImage should be visible.
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.
Here is the image with LaunchImage added in Assets.xcassets.
Simulator Image on launching App.
Hope it helps in solving your problem.
Have you changed the setting for your project so that it points to the Asset Catalog as the source for your Launch Image?
I need some help figuring out why I can't get a launch icon and appicon to apply to my project. I am running xcode Version 6.3.2. Note: another developer has already applied an appicon The following I have tried:
I created an asset catalog and added new app icon and launcher image via the plus sign button in the lower left of the asset window.
In the general settings of the app I clicked on "Use Asset Catalog" for both the launcher icon source and app icon source. I selected my asset catalog and it prompts me to migrate images, which I did.
My icon and launch icon are not applying even though I have followed these steps. How do I figure out why they are not applying?
EDIT:
All of the slots for the different devices are filled with a .png image. Now that I look at it I wonder if this could be the issue- when I select use asset catalog it migrates my images which creates a new subset of launch icons and all of those slots are empty. With that subset selected my project builds fine. If I select my original subset with the icons in the slots the build fails with message - The app icon set named "AppIcon" did not have any applicable content. Same for the launch icons.
Delete the app from the simulator or device and try again. Due to caching optimizations, sometimes resources are not updated if the name doesn't change.
You might also need to clean your project and rebuild it. Select Clean from the Product menu in Xcode.
It's a long shot, but your Asset Catalog may not be included in your target. Select the catalog file, open the File Inspector and check the Target Membership. Although I believe #Dave Batton has provided the correct answer.
I deleted my original launchImage image set.
Then went to "App Icons and Launch Images" in the project section of Xcode.
I de-selected "Launch Image Source" and then reselected it. I get the "Migrate launch images to an asset catalog". I choose an asset catalog and "Migrate" and then a launchImage image set opens up.
I add my files, but then I get a red compile warning.
I checked the Plist - no launchimage in there at all.
Previously, I got yellow warnings about Ambiguous content and the files being the wrong sizes - I check and rechecked - they were the right sizes!
How do I fix?
EDIT: I found this in my files. Do I just trash the selected folder?
Go to the project explorer and select the project. Click "Build Phases". At the bottom there's a section called "Copy Bundle Resources." I suspect you'll find two images.xcassets files there and, if so, remove one by highlighting and clicking the minus icon (there are legitimate reasons to have two, or more, but you'd have purposefully done that so it's outside the scope of this answer). On the remaining one add your images to the LaunchImage.
Your reason for adding two isn't clear so I'll add that if you are using multiple targets you can have different images.xcassets files for each target (xcode adds multiples by default). However, if most assets are the same and you don't want to manage multiples, you can use the same in all targets and write add a script to build phases to copy the different assets, like the launch image, over at compile time. This is also done in build phases: add a phase that runs a script then a copy (cp) line to copy images. Needless to say you should do this with very few assets: I use it for launch images and app icons.
Edited to add: there's a new scheme where launch images are in storyboards and/or xib's. I'm assuming that you're not using it because you said you were using the older launch images but, if you are, then just put your launch image in the storyboard/xib launch image file.
Hi as per your question please visit the below link:
EDIT:
I have tried to regenerate the issue which you are facing. please check your 'images.xcassets' you need to have both 'Launchimage' and 'AppIcon' in 'images.xcassets'. If you don't have either 'LaunchImage' or 'AppIcon' it will generate error.
Based on the image you have added it seems you have deleted image.xcassets from application but not moved to thrash.
You can follow the below image to set launch screen images.
1.) Before entering launch image in images.xcassets
2.) images.xcassets without launch screen image
3.) Add launch screen image in images.xcassets
4.) Set launch image in launch Image screen
This will help you to add new 'image.xcassets' in your application.
http://www.intertech.com/Blog/xcode-assets-xcassets/
5.) Folder structure after adding new image xcasset
6.) Launched the application after deleting and adding new image assets.
This will help you if you have removed just launch image from your 'images.xcassets' not your images.xcassets.
How to use Image.xcassets:
To set launch screen image and other images in your application.
https://www.youtube.com/watch?v=_36Y6rDcKP0&list=PLXCowKcXAVgrCe2Lezv0acRf4adQLshv2
Hope this will be more helpful.
I've been setting my own names on launch images for my apps in the Info.plist like
with the following images in bundle (with correct dimensions, 320x480 px for default.png and 640x960 px for default#2x.png etc.)
this have been working great prior to iOS 7 and Xcode 5. Now when I look in the General tab for the corresponding target in Xcode 5 my launch image files get mixed up from other targets in my project, which worries me, even though I haven't seen wrong launch image files when actually running the target. Should I be worried? The chosen images isn't in the build target so I should be fine there, but is there a risk of getting a blank image instead?
My main question is, can I use my default setup in Info.plist (that help auto detected respective launch images) for iOS 7, and if so, what should I name the corresponding launch images (now that there's the "iOS 6.1 and Prior" options as well with different dimensions)? This especially applies for the iPad Portrait Retina (iOS 7) that has new dimensions. The auto detection on iPad Portrait Non-Retina (iOS 7) refers to an image, not in the build target, that has the right dimensions. Again, when running a simulator with iPad Retina and iOS 7.0 the correct launch image shows.
Anden, I ran into the same problem today while adding a new target to the half dozen I already had that were set up in the same way that you set up yours.
I decided to use that "Use Asset Catalog" button, which took some work to set up, but has simplified things greatly in the end:
1- (optional) Delete (remove references only) the icon and launch image files from your project. I don't think you need the files to be in the project navigator anymore.
2- Choose your primary target, go to "General" and "App Icons" (as you showed above).
3- Press the "Use Asset Catalog" button, with the "Migrate Launch Images" checked as well.
4- This creates a file called "Images.xcassets" in your project navigator. Go there, and find the App Icon and Launch Image catalogs corresponding with the particular target. You can drag and drop image files from the finder into the slots in the catalog, and rename the icon/default groups from the list on the left.
5- Once you've got the image slots filled up, go back to the "General" for each target, and press the "Use Asset Catalog" button again for each target. Instead of creating a new xcassets file for each, you can store all the launch images and icon files in the same xcassets file.
I think it is a bug in xcode 5. I filed a bug, perhaps you should too (bugreport.apple.com). Make Apple aware things like this are not working well, and are taking our time and nerves.