mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-01-31 09:08:48 +08:00
Fix pixelated image in storyline
Reviewed By: seanxiao Differential Revision: D2563069 fb-gh-sync-id: 86fa47801c34669b7b0c2826e0e776717f5605dc
This commit is contained in:
committed by
facebook-github-bot-4
parent
a859d9e931
commit
4036eca570
@@ -58,17 +58,16 @@ RCT_EXPORT_MODULE()
|
||||
|
||||
// Note: PhotoKit defaults to a deliveryMode of PHImageRequestOptionsDeliveryModeOpportunistic
|
||||
// which means it may call back multiple times - we probably don't want that
|
||||
imageOptions.deliveryMode = PHImageRequestOptionsDeliveryModeHighQualityFormat;
|
||||
|
||||
BOOL useMaximumSize = CGSizeEqualToSize(size, CGSizeZero);
|
||||
CGSize targetSize;
|
||||
if (useMaximumSize) {
|
||||
targetSize = PHImageManagerMaximumSize;
|
||||
imageOptions.resizeMode = PHImageRequestOptionsResizeModeNone;
|
||||
imageOptions.deliveryMode = PHImageRequestOptionsDeliveryModeHighQualityFormat;
|
||||
} else {
|
||||
targetSize = size;
|
||||
imageOptions.resizeMode = PHImageRequestOptionsResizeModeFast;
|
||||
imageOptions.deliveryMode = PHImageRequestOptionsDeliveryModeFastFormat;
|
||||
}
|
||||
|
||||
PHImageContentMode contentMode = PHImageContentModeAspectFill;
|
||||
|
||||
Reference in New Issue
Block a user