gpt4 book ai didi

ios - UIImagePickerController 始终显示 640x640 图像

转载 作者:可可西里 更新时间:2023-11-01 04:27:55 25 4
gpt4 key购买 nike

当我在我的 iPhone 应用程序中显示一个 UIImagePickerController 时,它总是出现一个周围有框架的白色方 block ,用户可以放大和缩小图像并使其适合白色方 block 。它们适合白色方 block 的内容就是返回的内容:

- (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingImage:(UIImage *)img editingInfo:(NSDictionary *)info

它总是 640x640。

为什么用户不能选择整张图片?为什么会出现这个白色方 block ?

最佳答案

内置编辑非常有限。这是Apple documentation说:

Editing controls To specify whether the camera interface should offer the user controls for moving and scaling the captured picture, or for trimming the captured movie, set the allowsEditing property to YES (to provide editing controls) or to NO.

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 - UIImagePickerController 始终显示 640x640 图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8966453/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com