ios-UIImage写入相册

ios-UIImage写入相册
 NSData *imagedate=UIImagePNGRepresentation(image);//将相片转化成data,当然再这里和主题无关
 NSLog(@"%d",imagedate.length);//返回的是字节数
 UIImageWriteToSavedPhotosAlbum(image, self, @selector(image:didFinishSavingWithError:contextInfo:), @"liyang");//这个方法的作用是写到相册里面,下面那个是回调方法
- (void)image:(UIImage *)image didFinishSavingWithError:(NSError *)error contextInfo:(void *)contextInfo{
    NSLog(@"%@",error);
    NSLog(@"%@",contextInfo);
}
ios-UIImage写入相册

 

ios-UIImage写入相册,布布扣,bubuko.com

ios-UIImage写入相册

上一篇:ios 阻止GDB依附


下一篇:Android存储方式之SQLite的使用