UIImage -> CGImageRef

Wallter picture Wallter · May 20, 2011 · Viewed 33.8k times · Source

I'm building an Iphone app that needs to convert a UIImage to a CGImageRef. I have no idea how to do this and would love some help. I have no background in working with images... :)

Answer

Deepak Danduprolu picture Deepak Danduprolu · May 20, 2011

It is as simple as image.CGImage where image is a UIImage object.