iOS Open Source : MGImageUtilities

I recently bumped into an open source project created by Matt Gemmell, MGImageUtilities, which as the name implies offers two categories (more about categories) to extend the UIImage class.

The first category, UIImage+ProportionalFill, offers methods to resize images to fit into arbitrary sizes, the first method is for scaling images, while three additional methods are variations on cropping (from center, left/top and right/bottom).

The second category, UIImage+Tint, makes it easy to create different colors of an image by specifying a target UIColor – this can be helpful if you need an image to have various states, for example, active, inactive, etc. This second cateogry also includes a method in which you can define a fractional opacity for an image, which give the effect of an image being tinted.

A screenshot of the demo application included with MGImageUtilities is shown below:

Beyond the image processing project above, Matt has a number of interesting open source Cocoa projects, you can browse the list of his work here.

Suggestions For Open Source Projects?

If you have written, worked with or otherwise know of an interesting open source project, one that is focused on iOS development, feel free to send me a note. Even a simple class/category that offers something useful is welcome. Contact me with ideas and suggestions.