4

I want to create .icns for an app i made, i know how to make icons in png and .ico but i don't know much about it.

Which size should i create my icons before to convert them? I don't want my icons to look sharpen or blurred.

I tried just converting them but i don't know if it's just a matter of converting png or ico...

Any advice appreciated!

2
  • I have used the online tool at this site to create icns files. I am not sure it will help, but I though I would mention the site. Commented Mar 12, 2016 at 3:27
  • @DavidAnderson which sizes do you used for the original icon? To not to loose resolution while converting them i mean. Commented Mar 12, 2016 at 8:31

2 Answers 2

3

There's really no point in shoving a low resolution icon into the high resolution icns format. You'll likely need to modify your scaling and make much larger images and then use a tool to assemble the file.

Have a pretty in depth read of the OS X guidelines and the iOS guidelines (which are more complicated, but a shorter read):

It's quite a bit of detail on high resolution packing - so you'll likely need a few hours or days depending on how long you've been making resources.

In addition to letting Xcode make your icns resource and the iconutil command line tool, look into tiff2icns

5
  • In addition, I've written an AppleScript to take in an image and turn it into a .icns: I'd be happy to post it if anyone'd like. Commented Mar 11, 2016 at 21:42
  • 1
    Please do @JMY1000 - edit in or answer here or post a new "jeopardy" question. Ping me and link if it's elsewhere :-) Commented Mar 11, 2016 at 23:17
  • @bmike Thank you for the tips, of course, i am not using low resolutions images, i do all by svg so the only important thing for me is to know which sizes i should export the svg to png. Is it 48, 32, 16, 128, 256, 512, and 1024 wide images ? Commented Mar 12, 2016 at 8:31
  • I added a second link for iOS considerations. Apple requirements explanations for naming list these px sizes (duplicates are intentional) 512, 1024, 120, 180, 76, 152, 40, 80, 120, 29, 58, and 87 - see Table 5. Table 6 adds more mandatory and optional sizes for apps provisioned for iOS 6.1 and earlier, @sbaaaang Commented Mar 12, 2016 at 15:07
  • @bmike Added :) Commented Mar 12, 2016 at 23:51
4

In addition to @bmike 's answer earlier, here's an AppleScript that automates the process of .icns creation.

set export_folder to choose folder with prompt "Please select export folder." set isImage to false repeat while isImage = false set import_image to choose file with prompt "Please select image to covert." try tell application "Image Events" launch set test_image to open import_image if resolution of test_image = {} or resolution of test_image = {0, 0} then error ["Invalid Image"] end if set isImage to true end tell on error tell application "System Events" display dialog "Error: Selected file is invalid" with title "Error" with icon caution end tell end try end repeat try tell application "Finder" make new folder at export_folder with properties {name:"Icon.iconset"} end tell on error tell application "System Events" display dialog "Error: Folder \"Icon.iconset\" already exists, will overwrite unless canceled" with title "Error" with icon caution end tell end try set export_folder_path to POSIX path of export_folder set import_image_path to POSIX path of import_image set icon_folder_path to POSIX path of export_folder_path & "/Icon.iconset" do shell script "sips -z 16 16 " & import_image_path & " --out " & icon_folder_path & "/icon_16x16.png" do shell script "sips -z 32 32 " & import_image_path & " --out " & icon_folder_path & "/[email protected]" do shell script "sips -z 32 32 " & import_image_path & " --out " & icon_folder_path & "/icon_32x32.png" do shell script "sips -z 64 64 " & import_image_path & " --out " & icon_folder_path & "/[email protected]" do shell script "sips -z 128 128 " & import_image_path & " --out " & icon_folder_path & "/icon_128x128.png" do shell script "sips -z 256 256 " & import_image_path & " --out " & icon_folder_path & "/[email protected]" do shell script "sips -z 256 256 " & import_image_path & " --out " & icon_folder_path & "/icon_256x256.png" do shell script "sips -z 512 512 " & import_image_path & " --out " & icon_folder_path & "/[email protected]" do shell script "sips -z 512 512 " & import_image_path & " --out " & icon_folder_path & "/icon_512x512.png" do shell script "cp " & import_image_path & " " & icon_folder_path & "/[email protected]" do shell script "iconutil -c icns " & icon_folder_path & ";" display notification "ICNS Creator has finished generating an ICNS" with title "ICNS Creator" 
0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.