开发者

MyImagePicker from WWDC 2010 sample code displays nothing

开发者 https://www.devze.com 2023-02-02 06:01 出处:网络
I compiled and ran the MyImagePicker project from the WWDC 2010 sample code on my iPhone 3Gs with iOS 4.2.1, but it just gives me a blank table.Shouldn\'t it be populating with data from my photo roll

I compiled and ran the MyImagePicker project from the WWDC 2010 sample code on my iPhone 3Gs with iOS 4.2.1, but it just gives me a blank table. Shouldn't it be populating with data from my photo roll?

Interestingly, I also get a blank table in the UIImag开发者_Go百科ePickerController Clone from iCodeBlog.

Both of these projects apparently use the AssetsLibrary framework -- what am I missing here?


I shouldn't have assumed that the picker would automatically select from the saved photos album.

Change the following line in RootViewController.m from:

NSUInteger groupTypes = ALAssetsGroupAlbum | ALAssetsGroupEvent | ALAssetsGroupFaces;

to:

NSUInteger groupTypes = ALAssetsGroupSavedPhotos;

to just get saved photos... It turns out that this isn't any better for my purposes than the stock UIImagePickerController, but it was a learning experience.

0

精彩评论

暂无评论...
验证码 换一张
取 消