Kirti Nikam
Kirti Nikam

Reputation: 2206

How to hide iCloud images in picker while picking image from photos using Photos Framework

In my app, I am allowing the user to select photos from the album, but here I want to hide iCloud images for selection. I found this solution but not working for me, the iCloud image is visible to select. Picker should show local images and camera roll images for selection.

I tried below AssetCollection subtypes:

PHAssetCollectionSubtypeAlbumMyPhotoStream : found iCloud image PHAssetCollectionSubtypeSmartAlbumUserLibrary: found iCloud image

Any idea how to do that? Which PHAssetCollectionSubtype should have to use?

Upvotes: 0

Views: 476

Answers (1)

holtmann
holtmann

Reputation: 6303

What do you mean exactly with iCloud images?

  1. There is the iCloud Photo-Library. The images are just normal assets in the All Photos album. There is no way to hide them as the iCloud Photo Library does not differantiate between what's on the device and what's in the Cloud. The only thing you can do is prevent network access (cloud download), when you request the full resolution image/data, video data for the asset.
  2. There are "Shared Photostreams and "My Photostream". These are not part of "All Photos" and in separate albums. These you can just exclude by not including the albums in the interface

Upvotes: 0

Related Questions