How to create an image from a UIView / UIScrollView

Posted by Andre on Stack Overflow See other posts from Stack Overflow or by Andre
Published on 2010-03-23T15:01:09Z Indexed on 2010/03/23 15:03 UTC
Read the original article Hit count: 639

Filed under:
|
|
|
|

Hi,

I have an image in an UIScrollView, that can be scrolled and zoomed.

When the user presses a button, I want the code to create an image from whatever part of the UIScrollView is inside an area I specify with a CGRect.

I've seen code to crop UIImages, but I can't adapt it to do the same for a view, because it uses CGContextDrawImage.

Any thoughts?

Cheers, Andre

© Stack Overflow or respective owner

Related posts about xcode

Related posts about iphone