Search results for

[tags:education and kids]

33 results found

Post

Replies

Boosts

Views

Activity

Persistence of photo access permission ?
I understand that when the user picks a set of images in the PKPicker mode on the Library object then the usual attributes such as local identifier are returned in the query. If an app stores the local identifiers, can the app load the images in another session with just the local identifier? i.e. is the user permission persistent for later requests via a query on the Photo Libary?
4
0
1.5k
Jun ’20
PHPickerViewController: Controling the selected video's resolution?
Hello, does PHPhotoPickerViewController offer any options to specify which resolution should the selected video to be? Meaning can it do automatic compression like UIImagePickerViewController with videoExportPreset settings? Or is this supposed to be handled in the app itself? Say I want to always have Full HD or 4K videos (if available) how would I go about achieving that? Thanks
1
0
1.5k
Jun ’20
What did you mean by "non-destructive image editing" in the PHPicker session?
When the presenter lists use cases that you still need to use the old picker (requesting the user permission to access the Photo Library), they mention: Non-destructive image editing; Photo Library organization. I understand that the photo library organization means managing albums and deleting photo, for instance. But it's not clear what the non-destructive image editing means. Is it referred to the allowsEditing property that UIImagePickerController has but PHPicker doesn't? Thank you in advance!
1
0
649
Jun ’20
Load video from PHPhotoPicker without photo library permissions?
The sample code - https://developer.apple.com/documentation/photokit/selecting_photos_and_videos_in_ios for PHPhotoPicker doesn't include an example of how to load a video. I got it working by using the PHPickerResult’s assetIdentifier and PHAsset.fetchAssets(withLocalIdentifiers:options:), but that requires additional photo library permissions. How can I load a movie directly from the PHPickerResult?
10
0
9.4k
Jun ’20
How to correctly load video selected with PHPickerViewController?
Hello! I am playing around with the PHPickerViewController and so far I was able to get the selected images by loading them into UIImage instances but I don't know how to get the selected video. Below is the relevant implementation of the method: func picker(_ picker: PHPickerViewController, didFinishPicking results: [PHPickerResult]): let provider = result.itemProvider guard provider.hasItemConformingToTypeIdentifier(AVFileType.mov.rawValue) else { return } ttttttprovider.loadItem(forTypeIdentifier: AVFileType.mov.rawValue, options: nil) { (fileURL, error) in ttttttttif let error = error { ttttttttttprint(error) ttttttttttreturn tttttttt} ttttttttguard let videoURL = fileURL as? URL else { return } ttttttttDispatchQueue.main.async { ttttttttttlet fm = FileManager.default ttttttttttlet destination = fm.temporaryDirectory.appendingPathComponent(video123.mov) tttttttttttry! fm.copyItem(at: videoURL, to: destination) ttttttttttlet playerVC = AVPlayerViewController() ttttttttttplayerVC.player = AVPlayer(url: dest
13
0
9.9k
Jul ’20
Why is there an error when loading livePhoto in PHPicker without the photo library premissions?
hello,I am trying to figure out how to get livePhoto、gif and the picture on the icloud in PHPicker without the Photo Library permissions, but I get the error message like this : 2020-07-10 20:38:42.314255+0800 NewsInHouse[1307:315714] error = Error Domain=NSItemProviderErrorDomain Code=-1000 Cannot load representation of type com.apple.live-photo-bundle UserInfo={NSLocalizedDescription=Cannot load representation of type com.apple.live-photo-bundle, NSUnderlyingError=0x282049680 {Error Domain=NSCocoaErrorDomain Code=260 未能打开文件“7B1C8EE4-4A3E-4287-9369-8592943BC4AD.pvt”,因为它不存在。 UserInfo={NSURL=file:///private/var/mobile/Containers/Shared/AppGroup/3343D5E0-FD07-49AB-9131-3DADE85A46DC/File%20Provider%20Storage/7B1C8EE4-4A3E-4287-9369-8592943BC4AD.pvt, NSFilePath=/private/var/mobile/Containers/Shared/AppGroup/3343D5E0-FD07-49AB-9131-3DADE85A46DC/File Provider Storage/7B1C8EE4-4A3E-4287-9369-8592943BC4AD.pvt, NSUnderlyingError=0x2820042d0 {Error Domain=NSPOSIXErrorDomain Code=2 No such file or directory}}}} 2020-07-
2
0
2.4k
Jul ’20
How to check if the selected asset is not available because my app has been put in restricted mode
Hello there 👋 I'm trying to use the new PHPickerViewController and I have a question: how can I detect if my app has been put in restricted mode and the user opens the picker to select an image that my app hasn't access to? To clarify: I know how to detect if I my app is limited mode, I would like to know if the selected image is not available. The point is that I use the picker in order to retrieve the corresponding PHAsset and if my user selects in the picker a photo for which I can't retrieve the corresponding PHAsset because my app doesn't have the permission, I would like to warn him about what's going on. Thanks in advance 🙏
3
0
1.4k
Aug ’20