iOS菜鸟学习——图片resize的实现

UIGraphicsBeginImageContext( newSize );
[sourceImage drawInRect:CGRectMake(0, 0, newSize.width, newSize.height)];
UIImage* newImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return newImage;


你可能感兴趣的:(ios)