How do I set the images so that I can archive and validate my app? The screen looks like this now:
So the first one says 29pt, but then it also says 2x. So do I put a 29x29 image or a 58x58 image? And where do I put all of the other ones? (I know that there are more sizes than 29, 40, and 60).
Anyway, what I tried was I dragged a 29x29 png onto the first slot, a 40x40 onto the second, and a 60x60 onto the third and fourth. When I went to Product->Archive, I get
/Users/kendon/Documents/iPhone Apps/Sales Tool/Sales Tool/Images.xcassets: The app icon set named "AppIcon" did not have any applicable content.
I recently found this App called Icon Set Creator in the App Store which is free, without ads, updated on new changes, straight forward and works just fine for every possible icon size in OSX, iOS and WatchOS:
In Icon Set Creator:
Drag your image into the view
Choose your target platform
Export the Icon Set folder
In XCode:
Navigate to the Assets.xcassets Folder
Delete the pre existing AppIcon
Right click -> Import your created Icon-Set as AppIcon and you're done
Update: Unless you love resizing icons one by one, check out Schmoudi's answer. It's just a lot easier.
Icon sizes
Above image from Designing for iOS 9. They are the same for iOS 10.
How to Set the App Icon
Click Assets.xcassets in the Project navigator and then choose AppIcon.
This will give you an empty app icon set.
Now just drag the right sized image (in .png format) from Finder onto every blank in the app set. The app icon should be all set up now.
How to create the right sized images
The image at the very top tells the pixels sizes for for each point size that is required in iOS 9. However, even if I don't get this answer updated for future versions of iOS, you can still figure out the correct pixel sizes using the method below.
Look at how many points (pt) each blank on the empty image set is. If the image is 1x then the pixels are the same as the points. For 2x double the points and 3x triple the points. So, for example, in the first blank above (29pt 2x) you would need a 58x58 pixel image.
You can start with a 1024x1024 pixel image and then downsize it to the correct sizes. You can do it yourself or there are also websites and scripts for getting the right sizes. Do a search for "ios app icon generator" or something similar.
I don't think the names matter as long as you get the dimensions right, but the general naming convention is as follows:
Icon-29.png // 29x29 pixels
Icon-29#2x.png // 58x58 pixels
Icon-29#3x.png // 87x87 pixels
Launch Image
Although you can use an image for the launch screen, consider using a launch screen storyboard file. This will conveniently resize for every size and orientation. Check out this SO answer or the following documentation for help with this.
Useful documentation
App Icon
Launch Screen
The Xcode images in this post were created with Xcode 7.
To save a bit time:
1) You can mark your app icon images all in finder and drag them into your Assets catalog all at once by dragging into one of the empty slots of the app icon imageset. When you hold your drag over the slot, several of the other slots look selected and when you drop those all will be filled up at once. Note that this works in XCode 8 (I haven't tried XCode 7), but in XCode 9 beta not yet.
2) The "Technical Q&A QA1686" apple documentation site has the sizes per app icon slot already calculated for you in a nice image and also contains the correct image names conventions.
I've tried most of the above and a few others and have found https://appicon.co to be the easiest, fastest, and provides the most comprehensive set.
Drag your image onto the screen
Click Generate
Open the file just downloaded to your Downloads folder
Here, you may be able to drag this entire folder into Xcode. If not:
Double-click the Assets.xcassets folder
Select all files
Drag them to Assets.xcassets
Rename it to AppIcon
The correct sizes are as following:
1)58x58
2)80x80
3)120x120
4)180x180
I use a tool called Prepo to produce all the right image sizes. You simply feed the app you image file and it will spit out each necessary file with an appropriate name.
Once you do this, you can then drag in the appropriate files or simply point to your Prepo exported folder.
Now a days is really easy to set app-icon, just go to
https://makeappicon.com/ add your image, they will send you all size of App-icon (Also for watch & itunes as well), now Click Assets.xcassets in the Project navigator and then choose AppIcon. Now you just have to drag n drop the icon as required.
I found App called Iconizer. You can find repository on github. Iconizer can generate app icons for OS X, iPad, iPhone, CarPlay and Apple Watch with just one image.
Simply Drag and Drop your icon onto Iconizer, select the platforms you need and whether or not you want all platforms generated into one asset catalog, then hit export.
After that just replace (delete and import) your AppIcon in the Assets.xcassets
In the left list, right click on "AppIcon" and click on "Open in finder"
A folder with name "AppIcon.appiconset" will open.
Paste all the graphics with required resolution there.
Once done, all those images will be visible in this same screen(one in your screen shot). then drag them to appropriate box.
App icons have been added.
Same process for Launch images.
Launch images through this process are added for iOS 7 and below.
For iOS 8 separate LaunchScreen.xib file is made by default.
I quite like this app made by Jordi Bruin called Bakery
It allows emoji and SFSymbols for quick prototyping (not for the App Store in this case!)
It is as easy as drag and drop your design to the app and then again drag and drop to the asset catalog without having to fill in all the sizes by hand.
This is a very frustrating part of XCode. Like many, I wasted hours on this when I switched to a newer version of xcode (version 8). The solution for me was to open the properties for my project and under the "App Icons and Launch Images" choose the "migrate" option for the icons. This made absolutely no sense to me as I already had all my icons there, but it worked! Unfortunately I now seem to have two copies of my launcher icons in the project though.
As per updated version(Xcode 8.3.3) I saw that below resolution are required for all fields of AppIcon sets.
40x40
58x58
60x60
80x80
87x87
120x120
180x180
It comes with hdpi, xhdpi, xxhdpi etc.
Hope it will helps others.
Edited to 120x120
You can easily do it without resizing yourself or doing anything, just choose your icon at an app store icon generator website
https://getappscreenshots.com/app-icon-generator and it'll generate all required files and all icon sizes so you can just copy the files and paste in your project's folder!
You can get away with just adding a single image of size 1024*1024px.
Just add the image in like so
and select single size in the menu to the right.
Related
I've looked at other questions with the same issue and did what was suggested in them but keep getting the same error.
I've dragged 120x120 file into my project, cleaned, built, archived, same error.
I've dragged 120x120 file into the asset catalog manually, cleaned, built, archived, same error.
Here's a pic of my asset appicon:
There is no drag and drop for 120x120. Where am I suppose to add it?
Thanks
Dont drag images in asset.
Go to this link - https://makeappicon.com
Upload your 1024 image, it will email you the icons for iOS and Android as well.
Just copy and paste AppIcon.appiconset file into bundle.
You probably have already solved this, but I'd like to share an observation about this topic as I'm currently struggling with the same problem.
When you generate an app icon set with tools like makeappicon.com, chances are that not all possible icon variants are created. For example, old icon sizes (for iOS 5/6) are probably not produced.
In Xcode's assets editor (at least in Xcode 8.2.1) you only see the slots for which an icon is provided; for me this led to the misinterpretation that all possible icons are present. However, if you manually add an empty icon set in Xcode ("+" -> "New iOS App Icon"), you will see that there are more possible slots then are filled by the icon tool.
In my case the problem was that the deployment target was set to iOS6, but some icons required for iOS6 were not included in the icon set; so I created a new, empty icon set, manually dragged in the files which were created by my icon tool, and then created the missing icons by hand.
I have been desperately trying to add my images into the App Icon set in Xcode but it does not only is allowing me to add in my 960x670 image, then it complains that it does not fit the size dimensions. It does not allow me to place my 120x120 image and others that fit the size dimensions.
By the way, my method of adding in the images is first dragging them into assets.xassets (the general images folder) and then opening the AppIcon set and trying to drag those images into slots in the Appicon Set.
Why is this happening? Thank you!
960x670 image is not allowed to set AppIcon, you can read doc following
https://developer.apple.com/library/ios/recipes/xcode_help-image_catalog-1.0/chapters/AddingLaunchImagestoanAssetCatalog.html
You need to have images of those separate specified sizes, and then you need to drag them into the place that is alotted for each size. You can either resize the icon manually or download software from the Mac app store to do it for you.
I am a newbie in iOS. I want to set Launch Image in my app. And I'm using Asset Catalog. And I know I have to drag and drop the image to the boxes that shows up when I'm using Asset Catalog. But a weird thing which is happening at that time is when I'm trying to drag-drop, it just comes back . As if Xcode is telling me NO PLACE HERE. Xcode doesn't let me set my Launch Images. I'm not able to DROP my images in those boxes. And I know the sizes of my images are quite correct. 640*960, 640*1136, 750*1334, 1242*2208.(And I don't want to use LaunchScreen because it only supports iOS 8 and later.)
It's even more weird that people are down voting without even telling the reason. (If you are not good enough to help at least don't discourage newbies)
Got the solution.
Just answering my question so that if anyone is having same problem then here is the solution. My problem was because by mistake I was using images of "jpg" format where in fact I should have used "png" . Now I'm using "png" and it works perfect.
Click on images.xcassets. You should see app icon in the list. At the bottom of that column there is a plus and minus button. Click the plus button.
Click on new Launch Image in the list. This covers iPad's and iPhone's from iOS 5-8 and covers portrait and landscape.
Launch screen can also be support for ios 8,
What you need to do set the Go to project->Media.xcassets on right side information tab you need to select iOS 7.0 and later sizes.
Then you set your launch screen inside the Launch images.
It will work definitely.
By apple provide the document Adding an iOS App Icon Set or Launch Image Set
Thanks
open Images.xcassets of your project
Drag file one by one on boxes as per its size.
See following image.
After doing all Remove LaunchScreen.xib file from your project
And remove Launch screen interface file base name from your plist file.
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.
I am trying to put my app on the market and am granted with this error everytime I try:
Ipad: icon.png: dimensions (57 x 57) don't meet the size requirements. The icon file must be 72x72 pixels in .png format.
I have seen the endless posts about about modifying the .plist and also Edit Project Settings -> Build -> uncheck Compress PNG Files( Icon.png file error in universal app ). I have done both of this. I have also went through apples guide for universal app Icons and followed that as well. However I noticed a difference in the .plist file I have and they have (http://developer.apple.com/library/ios/#qa/qa1686/_index.html). (Mine has a Primary Icon attribute ) Is there something I am missing or is the apple documentation our of date?
When I change the icon to 72x72 I then get the same error except it says the icon file must be 57x57. It seems like it's trying to use icon.png for both the iphone and ipad icon when It should be using icon-72.png for ipad and icon.png for iphone. Is this defined somewhere else?
First of all I'm not sure if this is a rule or if it's just common practice, but your icons should start with a capital "I". Second, your iPad icon should be 72x72 not 57x57 like the iPhone icon. And finally, you're missing your iPad retina icon "Icon-72#2x.png" 144x144px.
Full break down of icons.
Icon.png = 57x57 iPhone non retina
Icon#2x.png = 114x114 iPhone retina
Icon-72.png = 72x72 iPad non retina
Icon-72#2x.png = 144x144 iPad retina
If you make sure your icons are exactly as I've listed then you won't have any problems.
If you are still experiencing problems after making these changes then try deleting all icon images from the project, and deleting the icon keys from your .plist file.
Then re-add the images to the project by dragging them directly to their corresponding placeholder in the summary tab of Xcode's navigator.
Well, I agree with #NSPostWhenIdle, But as far as the Naming conventions he is right, if you are adding directly to the plist,
But when it is concerned with Xcode , from Xcode 4.2, when you open the target settings -> Summary
I hope that you are using Xcode later than 4.2
And when you mouse over the App Icons section, it will show the size of icons and right click there and add icons. Xcode itself fix the names for your icons according to the size of the icons which you are selecting like this
So, No matter of fighting with the naming conventions of iCons, and if you add like this, these icon names are fixed my Xcode itself and these icons are automatically added to the plist File as well.
I removed the icons from my project via the file system, renamed them as suggested by NSPostWhenIdle and sree charan. I then dragged and dropped them into the the app icon section and removed and readded the entries in the .plist via a text editor. However this still wasn't effecient enough, I thought that removing the files from the project in the file system would remove the references in the project, THIS IS NOT TRUE. I suggest to anyone that with icon problems after this to do what I previously stated and remove all icon references/files via the project and NOT the file system before re-adding.
Your icon.png is probably not exactly 57x57. in finder, right click on the icon.png, get info. If it still says 57x57, then I am not sure why its throwing that error.
I had a similar issue when my icon.png was 57x56 (which I had never checked until xcode whined).
IF these dont work, restart your Xcode and or Mac, make a clean build.
I just want to add (for others finding this question) that I recently ran into this error, but in my case it was complaining that 76x76 did not meet the requirement of 72x72, which didn't make any sense to me since our iPad app is iOS 7 only and therefore according to all official documentation only requires icons of size 76x76 and 152x152.
Icon dimensions (76 x 76) don't meet the size requirements. The icon file must be 72x72 pixels, in .png format.
Anyhow it turned out the person uploading the binary was using an older version of Application Loader (from Xcode 4.6) and this check was happening client-side before the upload even took place.
Submitting the same binary using the newer Application Loader from Xcode 5 had no problem!