Questions tagged [phpickerviewcontroller]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
46 views

iOS 17 swift get GPS Location from Image [duplicate]

I am fetching an image from the photo library and fetch the GPS Location data, but it's not working. This needs to work on iOS 17 as well, so I used PHPicker. kCGImagePropertyGPSDictionary is always ...
Ramprasath Selvam's user avatar
0 votes
1 answer
52 views

`PHPickerResult.itemProvider.canLoadObject(ofClass: UIImage.self)` returns `false` on iOS 17

I'm using PHPickerViewController. In the delegate method, I load the images like this: results.forEach { if $0.itemProvider.canLoadObject(ofClass: UIImage.self) { $0.itemProvider....
iMoeNya's user avatar
  • 682
0 votes
0 answers
26 views

How to handle deselection event on PHPickerViewController?

I'm trying to register a deselection event on PHPickerViewController but picker() function is being called only on selection event not on deselection event. Not even updateUIViewController() is being ...
siflJebatkundy's user avatar
2 votes
1 answer
64 views

How to handle callback from PHPickerViewController in a KMM project?

I'm working on a KMM application with a video picking feature. For the iOS implementation, I'm using a PHPickerViewController. The view controller is well presented but I don't know how to handle the ...
François Legrand's user avatar
0 votes
0 answers
8 views

Restrict ReplayKit from recording photo gallery/ DocumentPicker when recording the app

I have a requirement where I want to screenshare the app's screen to the participants in the meeting in the app. I use ReplayKit to record the app's screen. However, I want to restrict recording the ...
Surya Vineeth's user avatar
0 votes
0 answers
14 views

Notification when a photoGallery/DocumentPicker is opened from the iOS app

I have a requirement where I need my sdk to be notified when the user in the host app opens a system UI such as PHPickerViewController/UIImagePickerViewController/UIDocumentPickerViewController etc. ...
Surya Vineeth's user avatar
0 votes
2 answers
160 views

PHPickerViewControllerDelegate — special handling for limited case? Why is didFinishPicking not working seamlessly?

I am using the new PHPickerViewController & Delegate on iOS15+. I want my code to get get a callback from the picker (regardless of full photo access or limited) that the user has selected photo x,...
Msencenb's user avatar
  • 5,104
0 votes
0 answers
40 views

PHPickerViewController swipe to dismiss stops working after selecting photo

I present a PHPickerViewController as a pagesheet. It is possible to close/dismiss the picker interactively by just swiping down (or tapping outside on iPad). However once you tap a photo this no ...
Janneman's user avatar
  • 1,123
0 votes
0 answers
67 views

Problem Updating "Limited Library" Selection with PHPickerViewController With Choice "Select Photos"

Context: I'm building an app where a user can select Screenshots from their Photos Library, and display them in a more organized manner. These images are not saved to a database, but instead are ...
robinyapockets's user avatar
0 votes
0 answers
54 views

How to solve PHPickerViewControllerDelegate Error Domain=NSCocoaErrorDomain issues?

I have a problem choosing multiple images from the photo gallery using PhotoUI. If I pick 6 photos in UICollectionView it's showing 5 photos. Logs: Filename: IMG_0001 File Address: <...
Shahriar Hossain's user avatar
0 votes
1 answer
21 views

Can I pre-populate a search in iOS PHPicker?

Let's say I have an iOS "Cats" app that I want my users to select photos. Is there a way to open PHPicker with a search term pre-populated with "cats"?
user1669396's user avatar
0 votes
0 answers
33 views

preselectedAssetIdentifiers + PHPickerViewController

Interesting problem I found here. I am trying to load in pre-selected identifiers via preselectedAssetIdentifiers, which is working correctly. Essentially, I am letting my users edit photos, and as ...
daredevil1234's user avatar
1 vote
0 answers
77 views

PHPickerViewController Selected Photos Preview not showing close button

I am having this weird and odd behaviour with the PHPickerViewController. I am using SwiftUI and I have implemented the PHPickerViewController as a UIViewControllerRepresentable and everything seems ...
BrettS's user avatar
  • 295
0 votes
1 answer
45 views

AVAssetTrack nominalFrameRate is always 30 for high speed videos

For some reason the AVAssetTrack nominalFrameRate is always 30 for high speed videos. 120 FPS and 240 FPS videos' nominalFrameRate property is always 30. However, 60 FPS videos' nominalFrameRate is 60....
alwaysmemin's user avatar
0 votes
0 answers
23 views

Dismiss keyboard for PHPickerViewController not working

I'm using PHPickerViewController in my app and I want to keep it open even after the user selects an image. My flow is the following: after the user select the photo, another viewController is ...
MariaUngur's user avatar
0 votes
0 answers
117 views

PHPicker - All selected UIImages returning nil

Good day. I'm using PHPicker in order to implement the use of selecting multiple photos and I've encountered an issue when trying to handle the deselecting action. When I deselect one of the pre-...
lex's user avatar
  • 113
0 votes
2 answers
137 views

How to deselect a photo after re-opening the photo library?

I'm using PHPicker to handle multiple image selections. When a user initially selects, for example, 3 images from the photo library, they can re-open the photo library and deselect any of the selected ...
lex's user avatar
  • 113
0 votes
1 answer
140 views

How to import AVIF image in iOS by PHPicker

I use PHPicker for user to import photos, but UIImage not support the pic of .AVIF, so I want to get the origin data of .AVIF pic, this is my code: func picker(_ picker: PHPickerViewController, ...
zZz's user avatar
  • 1
0 votes
0 answers
201 views

PHPickerViewControllerDelegate load item using async await

I can't find much documented regarding the PHPickerViewControllerDelegate didFinishPicking function using async await and I'm not sure I understand how to use the NSItemProvider. Here is my delegate ...
David's user avatar
  • 305
-2 votes
1 answer
133 views

Problem with webp and PHPickerViewController

I have a simple image picker (code was found somewhere on the internet): struct ImagePicker: UIViewControllerRepresentable { @Binding var image: UIImage? func makeUIViewController(context: ...
misster's user avatar
  • 11
0 votes
0 answers
158 views

Swift PHPicker cancel button changes color

I am currently using the PHPicker from apple. Works great but whenever I switch to the album segment the cancel button changes colour to white, making it barely visible. When I switch back to all it ...
Mr_Bull3t's user avatar
0 votes
2 answers
55 views

How do I play a video which was selected from Gallery?

I have two viewcontrollers: GetStartedViewController (root viewController) and TrimVideoViewController. I pick a video from the root one using PHPicker and I need to play that video in the second ...
SunnySideUp's user avatar
1 vote
0 answers
1k views

How to get image URL from PHPickerViewController?

I want to select multiple images. Currently I was using UIImagePickerController. However, this does not allow multi-image selection as per this question. So I'm looking into implementing this using ...
Muhammed Mahmood's user avatar
0 votes
1 answer
790 views

Show Selected Image View on PHPicker

I already use PHPicker to view get may image. I want to ask how u show only show selected image when u pick a image? I already try many things and it always show all image in galery. Kindly help. ...
Sayur Kecambah's user avatar
0 votes
2 answers
861 views

Is request permission require for using PHPickerViewController & UIImagePickerController?

I have some confusion about permission with using PHPickerViewController & UIImagePickerController. Do I have to request permission for using it ? (Currently, I open it without request permission ...
Nawin P.'s user avatar
  • 233
2 votes
0 answers
323 views

Show user's Selected Image when user accesses photos

I tried to show only photo that I selected before, but it won't work and show all photos. How do I solve this issue? I tried to use permission to limited access but it end up showing all of the photos ...
Sayur Kecambah's user avatar
1 vote
1 answer
647 views

PHPhotoLibrary showing all photos not only selected [duplicate]

Trying to write a picker for the avatar in my app and when PHAuthorizationStatus is .limited and the user already selected some photos in LimitedLibraryPicker, I'm trying to open the picker in this ...
Liubomyr Havronskiy's user avatar
7 votes
2 answers
2k views

Getting a PAMediaConversionServiceErrorDomain error 2 when importing an image using a PHPickerViewController

I got this message when trying to import an image using a PHPickerViewController: 2022-10-29 12:52:17.775185+0200 screenfreeze[38500:5423936] [claims] 2AA2E9DE-9603-4723-B04C-35F09BB99667 ...
Tamás Sengel's user avatar
1 vote
0 answers
547 views

iOS 16.0 - PHPicker issue with PHPickerConfiguration config.selection = .people

I'm facing issues on 16.0 using PHPickerViewController with PHPickerConfiguration config.selection = .people. The PHPicker screen shows an error "Unable to Load Photos". Xcode 14.0.1. ...
fabrizio sposetti's user avatar
1 vote
1 answer
182 views

PHPicker can't load selected image to UIButton

I created a UIButton programmatically Which can pick profile photo. So I made image picker with PHPicker, and it shows well. But after I selected image, it doesn't show on the button. I thought the ...
LEE's user avatar
  • 13
0 votes
0 answers
136 views

PHPickerview result will not load videourl

I'm trying to get the video URL (video chosen from user camera roll) from PHPickerview result, however I'm receiving this error: It's saying that it can't load representation of type public.movie, ...
EAO123's user avatar
  • 55
0 votes
0 answers
117 views

Am i doubling the amount of time it takes for the video to upload (from user's camera roll)?

In one of my view controllers, I'm using PHPickerViewController. When I get my results, I then upload the URL to Firebase. It works fine, but with this line of code, try! FileManager.default.copyItem(...
EAO123's user avatar
  • 55
0 votes
1 answer
560 views

How to compress video after getting result from PHPickerViewController xcode swift

I know that UIImagePickerController allows you to compress media content upon selection. However, I'm not sure how to do the same with PHPickerViewController. How can I compress a video after getting ...
EAO123's user avatar
  • 55
0 votes
1 answer
386 views

Track progress of PHPickerViewController video upload, takes way too long to upload videos over 5 minutes

I set this up in my code and it works fine. I try to download the URL from user library, and upload it to Firebase Storage through another function, but for videos over 5 minutes, it seems to take ...
EAO123's user avatar
  • 55
0 votes
1 answer
137 views

firebase upload error Domain=NSItemProviderErrorDomain Code=-1000 "Cannot load representation of type

So I set up a PHPickerViewController, and it uploads the videos from the camera roll (slowly ugh, but it does it). Sometimes, the video uploads. Other times, I get this error (especially with longer ...
EAO123's user avatar
  • 55
4 votes
1 answer
2k views

PHPickerViewController's Cancel Button is not working in iOS 15

I am using PHPickerViewController to pick Image for User Profile Picture Purpose in iOS 15. I am using UIKit framework. I have the following code: var pickerConfig = PHPickerConfiguration(photoLibrary:...
Kris2k's user avatar
  • 285
1 vote
0 answers
337 views

PHPicker result(s) incomplete

SwiftUI novice here. My PHPicker results show a weird behaviour. Whether I pick one image or several, often the result is empty for a single image or incomplete if multiple images are picked. Oddities:...
Landogarner's user avatar
0 votes
0 answers
603 views

Why does PHPickerViewController say "Unable to Load Photos"

I'm working on a project where I need the user to be able to select images from their camera roll. I was using a UIImagePickerController but for some reason it's not working anymore which I assume is ...
JonGrimes20's user avatar
1 vote
1 answer
92 views

PHPickerViewController not showing Photo Stream

We use PHPickerViewController to allow the user to pick photos to import into our app. Recently a user said they do not see their Photo Stream in the picker. Is there a way to get the Photo Stream ...
Nic Hubbard's user avatar
  • 41.7k
1 vote
1 answer
610 views

iOS PHPickerViewController does not provide Exif/Meta-Data

I am trying to read out some metadata from images which I fetched with the PHPickerViewController. var config = PHPickerConfiguration() self.phPicker = PHPickerViewController(configuration: config) if ...
Laufwunder's user avatar
0 votes
0 answers
1k views

UIImagePickerController in iOS 14+ with Limited Access

I have an App which needs to Access Photos and Videos from the iPhone Photos App. in iOS 14+ Apple has Introduced new API PHPicker but that still lacks lot of common feature like Cropping image, ...
Jatin Garg's user avatar
2 votes
0 answers
3k views

PHPickerViewController fails to load image

I have been trying to load an image from the photo library on a swifui app. I am running Xcode 13.2.1 and building IOS 15.2 My code is as below     @Binding var image: UIImage?     func ...
Pradyot's user avatar
  • 2,947
0 votes
1 answer
361 views

Multiple Button Images from PHPickerViewController

My View has four buttons. When you click on a button it launches the PHPickerViewController that allows a user to select an image from their device. How can I know which button was clicked so that I ...
Francis Muli's user avatar
0 votes
1 answer
439 views

How to upload multiple image on firebase using Swift's PHPickerController [closed]

so in Swift, you have the ability to upload an image/video with ease using UIImageViewController. I did research and came across PHPickerController and I am trying to incorporate that into my code - ...
Max Fritzhand's user avatar
1 vote
2 answers
853 views

Getting the size of a media item given a NSItemProvider?

I'm using a PHPickerViewController to allow the user to select a media item from their library. And the specific case of interest is when they select a video. I get a callback on the ...
Chris Prince's user avatar
  • 7,336
3 votes
1 answer
383 views

Replacing default images in a collection view with user selected photos- swift

So I have a collection view that populates three default images on each cell. The user can select images through the new PHPicker, what I want to accomplish is to replace default images with selected ...
ronix's user avatar
  • 193
-2 votes
1 answer
2k views

"Cannot load representation of type public.video" using PHPickerViewController

Trying to allow user to upload video from camera roll using PHPickerViewController (eventually to firebase storage) which is why I'm trying to get the url, but I'm getting this annoying error: Error ...
EAO123's user avatar
  • 55
1 vote
1 answer
1k views

PHPickerViewController: How to deselect the previous selected image when reopen the image picker

I create an app with PHImagePicker support. It works and I could select multiple photos from photo library and import them into this app. But when I reopen this pickerController, the previous selected ...
Zhou Haibo's user avatar
  • 1,724
11 votes
4 answers
2k views

PHPickerViewController tapping on Search gets error... "Unable to load photos"

I'm trying to implement a PHPickerViewController using SwiftUI and The Composable Architecture. (Not that I think that's particularly relevant but it might explain why some of my code is like it is). ...
Fogmeister's user avatar
  • 76.6k
1 vote
0 answers
929 views

"The file "..." couldn’t be opened because there is no such file" uploading video from phpickerviewcontroller to FirebaseStorageq

I'm trying to upload a video file using phpickerviewcontroller, but I'm running into an issue uploading the URL to FirebaseStorage. Here is some code: func uploadVideo(videoURL: URL) { let ...
EAO123's user avatar
  • 55