mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-22 22:25:57 +00:00
Update & document changes to ASPhotosFrameworkImageRequest handling of PHImageRequestOptionsDeliveryMode
This commit is contained in:
@@ -528,7 +528,9 @@ typedef void(^ASMultiplexImageLoadCompletionBlock)(UIImage *image, id imageIdent
|
||||
// Get the best image we can.
|
||||
PHAsset *imageAsset = [assetFetchResult firstObject];
|
||||
PHImageRequestOptions *options = [request.options copy];
|
||||
options.deliveryMode = PHImageRequestOptionsDeliveryModeHighQualityFormat;
|
||||
if (options.deliveryMode == PHImageRequestOptionsDeliveryModeOpportunistic) {
|
||||
options.deliveryMode = PHImageRequestOptionsDeliveryModeHighQualityFormat;
|
||||
}
|
||||
|
||||
[[PHImageManager defaultManager] requestImageForAsset:imageAsset
|
||||
targetSize:request.targetSize
|
||||
|
||||
@@ -48,8 +48,8 @@ extern NSString *const ASPhotosURLScheme;
|
||||
|
||||
@discussion Some properties of this object are ignored when converting this request into a URL.
|
||||
As of iOS SDK 9.0, these properties are `progressHandler` and `synchronous`.
|
||||
Note that PHImageRequestOptionsDeliveryModeOpportunistic is not recommended when using ASMultiplexImageNode,
|
||||
because it sends multiple images and only the first will be accepted.
|
||||
Note that ASMultiplexImageNode does not support PHImageRequestOptionsDeliveryModeOpportunistic
|
||||
because it sends multiple images, and that mode will be replaced by PHImageRequestOptionsDeliveryModeHighQualityFormat
|
||||
*/
|
||||
@property (nonatomic, strong) PHImageRequestOptions *options;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user