如何将所有照片从iPhone照片库读取到应用程序中,我将如何获取照片库的路径?
如何将iphone照片库中的所有图像读取到应用程序中,我将如何获取照片库的路径?
How to read all images from iphone photo library into application and how i would i get path of photo library??
要从iPhone照片库读取所有图像,请使用资产库框架".
To read all images from iPhone photo library, use the "assets library framework".
您可以在此处查看Apple的文档: http://developer.apple.com/library/ios/#documentation/AssetsLibrary/Reference/AssetsLibraryFramework/_index.html
You can check out Apple's documentation here: http://developer.apple.com/library/ios/#documentation/AssetsLibrary/Reference/AssetsLibraryFramework/_index.html
有一个名为"allPhotos"的ALAssetsFilter,您可以将过滤器与ALAssetsGroup中的setAssetsFilter:和enumerateAssetsUsingBlock:方法一起使用.
There is a ALAssetsFilter called "allPhotos", you can use the filter with the setAssetsFilter: and the enumerateAssetsUsingBlock: methods in ALAssetsGroup to achieve this.
以下是一些实现此目的的示例代码: http://www.icodeblog. com/2010/07/08/asset-libraries-and-blocks-in-ios-4/
Here is some sample code implementing this: http://www.icodeblog.com/2010/07/08/asset-libraries-and-blocks-in-ios-4/