源码下载:https://github.com/darling0825/DLPhotoPicker.git
封装了AssetsLibrary和Photos的API,支持iOS7和iOS8以上
- (UIImage *)originImage
{
@autoreleasepool {
if (_originImage) {
return _originImage;
}
__block UIImage *resultImage;
if (UsePhotoKit) {
// image after edited
PHImageRequestOptions *originRequestOptions = [[PHImageRequestOptions alloc] init];
originRequestOptions.version = PHImageRequestOptionsVersionCurrent;
originRequestOptions.networkAccessAllowed = YES;
originRequestOptions.synchronous = YES;
//sync requests are automatically processed this way regardless of the specified mode
//originRequestOptions.deliveryMode = PHImageRequestOptionsDeliveryModeHighQualityFormat;
originRequestOptions.progressHandler = ^(double progress, NSError *__nullable error, BOOL *stop, NSDictio