ios save image to album
2014-07-07 18:56
267 查看
- (void)savePhotoToAlbum
{
ZoomScrollView *zoomScrollView = (ZoomScrollView*)[self.scrollView
viewWithTag:BEGIN_TAG_FOR_IMAGE+self.currentImagePage];
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT,
0), ^{
UIImageWriteToSavedPhotosAlbum(zoomScrollView.imageView.image,
self, @selector(image:didFinishSavingWithError:contextInfo:),
nil);
});
}
- (void)image:(UIImage *)image didFinishSavingWithError:(NSError *)error contextInfo:(void *)contextInfo
{
if (error == NULL) {
dispatch_async(dispatch_get_main_queue(), ^{
//////////////
});
}
else {
//////////////////////////////////////
}
}
{
ZoomScrollView *zoomScrollView = (ZoomScrollView*)[self.scrollView
viewWithTag:BEGIN_TAG_FOR_IMAGE+self.currentImagePage];
dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT,
0), ^{
UIImageWriteToSavedPhotosAlbum(zoomScrollView.imageView.image,
self, @selector(image:didFinishSavingWithError:contextInfo:),
nil);
});
}
- (void)image:(UIImage *)image didFinishSavingWithError:(NSError *)error contextInfo:(void *)contextInfo
{
if (error == NULL) {
dispatch_async(dispatch_get_main_queue(), ^{
//////////////
});
}
else {
//////////////////////////////////////
}
}
相关文章推荐
- ios save image to album
- ios相机读取图片到相册writeImageToSavesPhotosAlbum出现的问题
- SSave ALAsset image to disk fast on iOS
- 微信小程序保存网络图片的方式1:getimageinfo+saveImageToPhotosAlbum
- 微信小程序保存网络图片的方式2:downfile+saveImageToPhotosAlbum
- wx.saveImageToPhotosAlbum将图片保存到本地
- FSDK_SaveImageToBuffer
- Applications using Launch Screen Files and targetting iOS 7.1 and earlier need to also include a Launch Image in an Asset Catalog.
- LINK - Xamarin.iOS + MvvmCross: UIImage binding to local storage image
- IOS高访微信聊天对话界面(sizeWithFont:constrainedToSize和stretchableImageWithLeftCapWidth的使用)
- IOS高访微信聊天对话界面(sizeWithFont:constrainedToSize和stretchableImageWithLeftCapWidth的使用)
- WJ的Direct3D简明教程1:Save Screen To the Image
- TWICImage.SaveToStream(Stream: TStream)方法修正
- IOS高访微信聊天对话界面(sizeWithFont:constrainedToSize和stretchableImageWithLeftCapWidth的使用)
- using Launch Screen Files and targetting iOS 7.1 and earlier need to also include a Launch Image in
- FSDK_SaveImageToHBitmap
- Add Custom Background Image to UINavigationBar in iOS 5
- Monotouch Save Image To Application(保存相册图片到你的应用程序)
- How to fill the background with image in landscape in IOS? 如何使image水平铺满屏幕
- FFMPEG -- Save streaming data as image in iOS