上传图片图像进行压缩后上传
时间:2014-10-16 20:41:24
收藏:0
阅读:190
图片压缩:
NSData *imageData = UIImageJPEGRepresentatioNSString *file_name = [TimeUtil getDateStringWithFormat:@"yyyy-MM-dd"];
[request setData:imageData
UIImageJPEGRepresentatio
UIImagePNGRepresentation
比較发现:
UIImagePNGRepresentation
譬如,相同是读取摄像头拍摄的相同景色的照片
比前者少了50多KB.
假设对图片的清晰度要求不高,还能够通过设置 UIImageJPEGRepresentatio
譬如,刚才拍摄的图片, 通过调用UIImageJPEGRepresentatio
但更改压缩系数后,通过调用UIImageJPEGRepresentatio
大大压缩了图片的数据量
原文:http://www.cnblogs.com/lcchuguo/p/4029572.html
评论(0)