10

I downloaded a set of 23 iOS App Icons from https://makeappicon.com that have the following filenames:

Icon-App-20x20@1x.png
Icon-App-20x20@2x.png
Icon-App-20x20@3x.png
Icon-App-29x29@1x.png
Icon-App-29x29@2x.png
Icon-App-29x29@3x.png
Icon-App-40x40@1x.png
Icon-App-40x40@2x.png
Icon-App-40x40@3x.png
Icon-App-57x57@1x.png
Icon-App-57x57@2x.png
Icon-App-60x60@1x.png
Icon-App-60x60@2x.png
Icon-App-60x60@3x.png
Icon-App-72x72@1x.png
Icon-App-72x72@2x.png
Icon-App-76x76@1x.png
Icon-App-76x76@2x.png
Icon-App-76x76@3x.png
Icon-App-83.5x83.5@2x.png
Icon-Small-50x50@1x.png
Icon-Small-50x50@2x.png
ItunesArtwork@2x.png

When dragging and dropping these onto a Xcode > New Project > Single View App > Assets.xcassets > AppIcon window all that happens is the following build warning:

The app icon set "AppIcon" has 23 unassigned children.

This is how I have previously created App Icons, but obviously something is wrong, and I have not been able to find any helpful documentation, or StackOverflow questions or answers. What do I need to do to get Xcode to accept these pngs as the App Icon?

Thank you for reading.

shim
  • 7,170
  • 10
  • 62
  • 95
Joseph Beuys' Mum
  • 2,015
  • 1
  • 17
  • 42

1 Answers1

14

There are only 3 significant points which Xcode takes into account when it accepts drag and drop of the batch of the image files into any image asset (not only App Icon):

  1. the real image width and height what Xcode gets right from the file
  2. scale qualifier in the filename: @2x, @3x
  3. idiom qualifier in the filename: ~ipad, ~car, ~mac, ~ios-marketing, ~watch-marketing

The additional qualifiers in the filename may be required to distinguish files with same scale and idiom suffixes but different size (e.g. 83.5@2x~ipad and 76@2x~ipad).

Example of possible drag and drop acceptable filenames with minimally required qualifiers is below.

iOS

// App Icons

app-icon@2x.png // iPhone | 60pt x 60pt | actual size: 120px x 120px

app-icon@3x.png // iPhone | 60pt x 60pt | actual size: 180px x 180px

app-icon~ipad.png // iPad | 76pt x 76pt | actual size: 76px x 76px

app-icon@2x~ipad.png // iPad | 76pt x 76pt | actual size: 152px x 152px

app-icon-83.5@2x~ipad.png // iPad Pro | 83.5pt x 83.5pt | actual size: 167px x 167px 

// Notification Icons

app-icon-20~ipad.png // iPad | 20pt x 20pt | actual size: 20px x 20px 

app-icon-20@2x~ipad.png // iPad | 20pt x 20pt | actual size: 40px x 40px 

app-icon-20@2x.png // iPhone | 20pt x 20pt | actual size: 40px x 40px 

app-icon-20@3x.png // iPhone | 20pt x 20pt | actual size: 60px x 60px 

// Settings Icons

app-icon-29.png // iPhone | 29pt x 29pt | actual size: 29px x 29px     

app-icon-29~ipad.png // iPad | 29pt x 29pt | actual size: 29px x 29px 

app-icon-29@2x~ipad.png // iPad | 29pt x 29pt | actual size: 58px x 58px

app-icon-29@2x.png // iPhone | 29pt x 29pt | actual size: 58px x 58px

app-icon-29@3x.png // iPhone | 29pt x 29pt | actual size: 87px x 87px

// Spotlight Icons

app-icon-40~ipad.png // iPad | 40pt x 40pt | actual size: 40px x 40px 

app-icon-40@2x~ipad.png // iPad | 40pt x 40pt | actual size: 80px x 80px 

app-icon-40@2x.png // iPhone | 40pt x 40pt | actual size: 80px x 80px 

app-icon-40@3x.png // iPhone | 40pt x 40pt | actual size: 120px x 120px 

// App Store

app-icon~ios-marketing.png // 1024pt x 1024pt | actual size: 1024px x 1024px 

Mac

app-icon~mac.png // actual size: 16px x 16px

app-icon-16@2x~mac.png // actual size: 32px x 32px

app-icon-32~mac.png // actual size: 32px x 32px

app-icon-32@2x~mac.png // actual size: 64px x 64px

app-icon-128~mac.png // actual size: 128px x 128px

app-icon-128@2x~mac.png // actual size: 256px x 256px

app-icon-256~mac.png // actual size: 256px x 256px

app-icon-256@2x~mac.png // actual size: 512px x 512px

app-icon-512~mac.png // actual size: 512px x 512px

app-icon-512@2x~mac.png // actual size: 1024px x 1024px | also used for Mac App Store

CarPlay

app-icon@2x~car.png // 60pt x 60pt | actual size: 120px x 120px

app-icon@3x~car.png // 60pt x 60pt | actual size: 180px x 180px

Apple Watch

The correct format for qualifying roles (e.g. Companion Settings or Quick Look) and subtypes (38 mm, 42 mm) was not found. So the only acceptable file here is the one for App Store.

app_icon~watch-marketing.png // 1024pt x 1024pt | actual size: 1024px x 1024px
M Jesse
  • 2,083
  • 5
  • 28
  • 35
pilgrim-ivanhoe
  • 164
  • 2
  • 5
  • I can't seem to get it to work automatically. Unless the Contents.JSON file has the "filename" param set for a particular icon, Xcode won't pickup my icon. – nr5 Nov 25 '19 at 08:07
  • 1
    Thank you so much for this. I have created an ["AppIcons.command"](https://gist.github.com/pd95/f8afdeb6139d96019bd60b11a70d6367) script to automatically convert the artwork into the various downscaled iPhone and iPad. My script can be executed on plain Mac OS without additional installs (thanks to `sips`). I hope this is useful to others too. – pd95 May 25 '20 at 15:50