如何将图片保存到 iPhone 照片库? [英] How to save picture to iPhone photo library?
本文介绍了如何将图片保存到 iPhone 照片库?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我需要做什么才能将我的程序生成的图像(可能来自相机,也可能不是)保存到 iPhone 上的系统照片库?
What do I need to do to save an image my program has generated (possibly from the camera, possibly not) to the system photo library on the iPhone?
推荐答案
你可以使用这个功能:
UIImageWriteToSavedPhotosAlbum(UIImage *image,
id completionTarget,
SEL completionSelector,
void *contextInfo);
如果您想在 UIImage
完成时收到通知,您只需要 completionTarget、completionSelector 和 contextInfo保存,否则可以传入nil
.
You only need completionTarget, completionSelector and contextInfo if you want to be notified when the UIImage
is done saving, otherwise you can pass in nil
.
请参阅有关UIImageWriteToSavedPhotosAlbum()
.
这篇关于如何将图片保存到 iPhone 照片库?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文