The Apple Icon Image format is the icon format used in Apple Inc.'s Mac OS X. It supports icons of 16 × 16, 32 × 32, 48 × 48, 128 × 128, 256 × 256, 512 × 512, and 1024 × 1024 pixels, with both 1- and 8-bitalpha channels and multiple image states (example: open and closed folders). The fixed-size icons can be scaled by the operating system and displayed at any intermediate size.
The file format consists of an 8 byte header, followed by any number of icons.
Header
Offset
Size
Purpose
0
4
Magic literal, must be "icns" (0x69, 0x63, 0x6e, 0x73)
4
4
Length of file, in bytes, msb first
Icon data
Offset
Size
Purpose
0
4
Icon type, see OSType below.
4
4
Length of data, in bytes (including type and length), msb first
8
Variable
Icon data
Compression
Over time the format has been improved and there is support for compression of some parts of the pixel data. The 32-bit ("is32", "il32", "ih32","it32") pixel data is often compressed (per channel) with a format similar to PackBits.[1]
Some sources mentioned that the OS supports both compressed or uncompressed data chunks.