#pragma mark 截图
- (UIImage *)capture:(UIView *)view
{
UIGraphicsBeginImageContextWithOptions(view.bounds.size, YES, 0.0);
[view.layer renderInContext:UIGraphicsGetCurrentContext()];
UIImage *img = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return img;
}ios 截屏,截图
原文:http://blog.csdn.net/zhangping871/article/details/41048013