The PHPhotoLibrary framework provides interfaces for viewing, editing and creating assets and collections managed by the IOS Photos app.
Questions tagged [phphotolibrary]
196 questions
3
votes
1 answer
Code 3300 error while trying to save a photo to iOS album
While trying to save a photo to a custom album on some devices we get the following error:
The operation couldn’t be completed. (PHPhotosErrorDomain error 3300).
code: 3300
This is the part of the code where the issue…

Ado
- 189
- 2
- 14
3
votes
2 answers
Why is the image quality so low? (swift)
I didn't like apples image picker so I decided to implement my own. I just finished the stage of getting all the users photos and displaying them in a collection view although I noticed that the difference in image quality is horrible. Here is my…

coder
- 35
- 6
3
votes
1 answer
How do I retrieve photos from Photos Library with PHAsset.fetchAssets(withLocalIdentifiers:) in Swift 5.2?
I'm trying to retrieve photos in Photo Library with asset.localIdentifier but PHAsset.fetchAssets(withLocalIdentifiers:options:) says:
and I have an error:
"[core] "Error returned from daemon: Error…

Nlion
- 31
- 2
3
votes
1 answer
Error on PHPhotoLibrary, cannot save video
I am trying to save a video in my photo library. But sometimes I get an error: The operation couldn’t be completed. (PHPhotosErrorDomain error -1.)
This is my code:
PHPhotoLibrary.shared().performChanges({
…

adri567
- 533
- 5
- 20
3
votes
1 answer
PHFetchResult extension that uses it's Generic ObjectType?
I'm trying to add an extension to PHFetchResult to pull the result objects out as a correctly typed array - and so far I can't figure out how to avoid the replication seen below. Aside from the type constraint the following extensions are identical.…

Mike Bedar
- 632
- 5
- 14
3
votes
1 answer
Not able to handle permission for NSPhotoLibraryAddUsageDescription
I am using uiactivityviewcontroller; In which there is a option to save photo to device.
So I added NSPhotoLibraryAddUsageDescription key for permission,
But not able to handle permission, once user click on Don't allow nothing happens when again…

JeanR
- 76
- 5
3
votes
2 answers
Saving a photo in a custom album fails when run for the first time
Hi I am creating a photo album app as a learning project and I am having some issues with the PHPhotoLibrary.shared().performChangesAndWait; the main issue is that when the method saveImage which has the PHPhotoLibrary.shared().performChangesAndWait…

JuValencia
- 212
- 1
- 3
- 17
3
votes
2 answers
Show Photos in custom album but not in Camera Role/My Photo Stream
I am working on PHPhotoLibrary, where I create an album and save image to it. But, the image being saved to the album also appears in the Camera Roll as well as My Photo Stream.
I searched a lot, nothing substantial found.
I wrote a function as…

Harish J
- 525
- 1
- 4
- 16
3
votes
1 answer
Metadata lost when saving photo using PHPhotoLibrary
I used to save a photo to the camera roll using ALAssetLibrary's writeImageToSavedPhotosAlbum:metadata:completionBlock, but that is now deprecated in iOS 9.0, so I switched to PHPhotoLibrary's version which looks like
[[PHPhotoLibrary…

Mitch D
- 79
- 9
3
votes
0 answers
NSItemProvider to PHAsset
I'm building an app and I need to get the PHAsset of an image from the NSItemProvider.
The NSURL I'm getting is for example:…

Andres
- 11,439
- 12
- 48
- 87
3
votes
3 answers
PHPhotoLibrary save a gif data
I can't find a similar method to ALAssetsLibrary->writeImageDataToSavedPhotosAlbum in the new PHPhotoLibrary since ALAssetsLibrary deprecated in iOS 9 I can't save GIF probably I'm using this code
[[PHPhotoLibrary sharedPhotoLibrary]…

Bader
- 825
- 1
- 9
- 26
3
votes
1 answer
Resetting [PHPhotoLibrary authorizationStatus]
In testing my app, I'd like to be able to reset the +[PHPhotoLibrary authorizationStatus] to check that the app behaves correctly when the library is not authorized.
I've tried deleting and reinstalling the app, however, the authorization status…

olynoise
- 2,016
- 2
- 19
- 32
3
votes
2 answers
PHPhotoLibrary requestAuthorization, not requesting
For testing, I was trying to recreate the system 'Requesting Access' popup experience.
Update:
Under iOS 11, after deleting the App, the system popup will be displayed again.
(previous question)
First time the App run (and the only time), the…

bauerMusic
- 5,470
- 5
- 38
- 53
3
votes
2 answers
"PHPhotoLibrary.requestAuthorization" not asking permissions in iOS 9
It's not asking permissions for gallery in iOS 9 but in iOS 8 it works fine. Maybe I need any permission key in info.plist?
PHPhotoLibrary.requestAuthorization({ (status) -> Void in
})

Artem Kislitsyn
- 395
- 1
- 3
- 18
2
votes
0 answers
"Photos" app shows different date & time depending on On/Off of 24-hour display in iOS when saving JPG files
I use PHPhotoLibrary in iOS to save JPG files to the camera roll.
There is a difference in the date and time displayed in the "Photos" app depending on whether the 24-hour display setting in iOS is set to On or Off when saving.
When saving with…

M.Masa
- 532
- 4
- 20