Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- PHImageRequestOptions *options = [[PHImageRequestOptions alloc] init];
- options.deliveryMode = PHVideoRequestOptionsDeliveryModeHighQualityFormat;
- options.networkAccessAllowed = YES;
- [[PHImageManager defaultManager] requestImageDataForAsset:asset
- options:options
- resultHandler:^(NSData * _Nullable imageData, NSString * _Nullable dataUTI, UIImageOrientation orientation, NSDictionary * _Nullable info) {
- NSURL *fileURL = info [@"PHImageFileURLKey"];
- UIDocumentInteractionController *controller = [UIDocumentInteractionController interactionControllerWithURL:fileURL];
- CGRect navRect = self.view.frame;
- self.controller = controller;
- [self.controller presentOptionsMenuFromRect:navRect inView:self.view animated:YES];
- }];
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement