1

Like the Photos App shows, all albums > all photos in a particular album > single photo view,

even I need a similar kind of a view. I have used UIImagePickerController and easily go to the second step. However, whenever I select an image, I can not show a slide show kind of a view, as UIImagePicker does not give me that.

I made another view controller , just to display these images in a pagenation form.

But, from the delegate method, didFinishPickingMediaWithInfo, when an image is selected, I get only that image using:

[info objectForKey:UIImagePickerControllerOriginalImage];

How do I know the images next to this image, and before this image, so that I can create a slide show?

Bobrovsky
  • 13,789
  • 19
  • 80
  • 130
Nikita P
  • 4,226
  • 5
  • 31
  • 55
  • I ran into same problem while ago and I try ELCAlbumViewer from github and With some modification I am able to generate the same what you want :) so give a try to it :) – The iOSDev Mar 12 '13 at 11:55
  • Give try to this [github](https://github.com/elc/ELCImagePickerController) this will give you the basic Idea how to give it start – The iOSDev Mar 12 '13 at 12:13
  • Try [this answer](http://stackoverflow.com/a/7297703/1132951) also [this one](http://stackoverflow.com/a/8302035/1132951) as it contains some code samples also – The iOSDev Mar 12 '13 at 12:18
  • Hi have put one dem project [here](https://github.com/AalokParikh/demoGallery) May this will help you :) – The iOSDev Mar 12 '13 at 13:26

1 Answers1

1

Check out the documentation for ALAssetsLibrary. To obtain a list of images or videos in the Photo library you would use the enumerateGroupsUsingTypes:usingBlock:failureBlock: method of an ALAssetsLibrary object. For instance, you could call this method, then as it asynchronously returns images and video you would build your array of images for the slideshow view.

Also check out this SO thread. The answer shows how to get an ALAsset object from the UIImagePickerController, which lets you find the URL of the image and other info about it.

Community
  • 1
  • 1
architectpianist
  • 2,562
  • 1
  • 19
  • 27
  • I know about ALAssetLibrary, I do not want to recreate what apple has given, I just want an extra slide show view – Nikita P Mar 12 '13 at 12:46