I want to pick an image from the gallery and show the preview for a user asking him/her to cancel/chose the image.
I can achieve this using the allowsEditing
option but I want to hide the square crop that is displayed to the user, instead I just want to show the selected image in a separate view and give him an option to cancel or chose the selected image.
You cannot disable the 'crop' option if you are allowing the editing for the media but one thing that you do is to get the original image even if the user crops a selected image. See below Apple mentioned in the documentation.
https://developer.apple.com/documentation/uikit/uiimagepickercontroller/infokey
Use the infoKey and get the originalImage instead of the cropped.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.