I want to create UIImage icon with different colors in PNG format. I have an original PNG UIImage. And If I set it with UIImageView with following code, I can easily get different UIImage with different tinted color appear in device:
self.imageView = [[UIImageView alloc] initWithImage:[originalImage imageWithRenderingMode:UIImageRenderingModeAlwaysTemplate]];
[self.imageView setTintColor:[UIColor whiteColor]];
My question is, after that, how can I export the tinted Image into PNG format so that I can use the image in other places. The origin of this question is when I use customer icon for SMPageControl, it only accepts UIImage and it seems you cannot get access to the UIImageView to set the tint color as above.