ImageOptim

Xcode's built-in (de)optimization

Xcode for iOS by default converts all PNG images to a non-standard iOS-specific PNG derivative. This format saves iOS devices a trivial conversion step during loading, because it uses premultiplied BGRA instead of RGBA color space. It doesn't affect rendering speed at all.

Xcode's conversion is applied even when it makes files bigger. It will undo ImageOptim's savings.

If size of assets or loading time is your priority (e.g. you want quicker application startup time and quicker AppStore download), disable Xcode's conversion:

In “Packaging” section of settings set “Compress PNG Files” to “NO” COMPRESS_PNG_FILES = NO;

Xcode plug-in

You can run ImageOptim directly from Xcode.

Better tool for the “CgBI” iOS format

If you must, you can generate iOS-only images using Scribd's patched AdvPNG tool, which has more efficient compression than Xcode's patched Pngcrush.

ImageOptim uses both AdvPNG and Pngcrush and other tools, such as PNGOUT and patched OptiPng that clears “dirty alpha”, achieving result similar to Xcode's premultiplied alpha conversion, but with regular PNGs.

“CgBI” support in ImageOptim?

I would rather not add support for Apple's PNG variant, as these files are unusable outside iOS, they don't improve loading speed, and on top of that Apple tries to patent this format.

The standard PNG8 with alpha channel format can be up to 70% smaller than 32-bit BGRA images, and that saves more resources than iOS's own format.