iOS-如何在启用allowEditing的情况下自定义UIImagePickerController中的裁剪区域? [英] iOS - How to customize the crop rect in UIImagePickerController with allowsEditing on?
问题描述
是否可以使用相机图像选择器来定义裁剪区域?
Is there any way to define the crop area rect using the camera image picker?
推荐答案
不幸的是,没有。
您必须实现自定义裁剪GUI才能获取默认设置以外的任何内容,如iOS相机编程主题所述:
You have to implement a custom cropping GUI to get anything other than the default, as stated in the Camera Programming Topics for iOS:
使用内置编辑控件时,图像选择器控制器将强制执行某些选项。对于静止图像,选择器将强制执行正方形裁剪以及最大像素尺寸。对于电影,选择器将强制执行最大电影长度和分辨率。如果要让用户编辑全尺寸媒体或指定自定义裁剪,则必须提供自己的编辑UI。
"When using built-in editing controls, the image picker controller enforces certain options. For still images, the picker enforces a square cropping as well as a maximum pixel dimension. For movies, the picker enforces a maximum movie length and resolution. If you want to let the user edit full-size media, or specify custom cropping, you must provide your own editing UI."
这篇关于iOS-如何在启用allowEditing的情况下自定义UIImagePickerController中的裁剪区域?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!