UIImageWriteToSavedPhotosAlbum(image,nil,nil,nil);
或者
#import
[[PHPhotoLibrary sharedPhotoLibrary] performChanges:^{
PHAssetChangeRequest *changeRequest = [PHAssetChangeRequest creationRequestForAssetFromImage:image];
changeRequest.creationDate = [NSDate date];
} completionHandler:^(BOOLsuccess, NSError *error) {
if(success) {
NSLog(@"successfully saved");
}
else{
NSLog(@"error saving to photos: %@", error);
}
}];