简体   繁体   English

使用相机的图像选择器未使用相机图像

[英]Imagepicker using camera have not use camera image

Using UIImagePickerController have to pick image from library or camera. 使用UIImagePickerController必须从库或相机中选择图像。 Library image picking worked without issues but camera image picking have issues. 库图像选择工作正常,但相机图像选择存在问题。 when i select camera option camera opened and took picture. 当我选择相机选项时,相机打开并拍照。 after took picture log displayed as "Snapshotting a view that has not been rendered results in an empty snapshot. Ensure your view has been rendered at least once before snapshotting or snapshot after screen updates.". 拍照后的日志显示为“快照未渲染的视图会导致快照为空。请确保快照之前至少渲染一次视图或屏幕更新后进行快照”。 when i click use photo button app crashed. 当我单击使用照片按钮应用程序时崩溃。

UIImagePickerController presentation is UIImagePickerController演示文稿是

let ImagePicker = UIImagePickerController()
ImagePicker.delegate = self
self.presentViewController(ImagePicker, animated: true, completion: nil)

It looks like bug because many developer get same error and have solution below that works for many developer.Hope any one of solution from following link will help to you.. 看起来像是错误,因为许多开发人员遇到相同的错误,并且下面的解决方案对许多开发人员都有效。希望以下链接中的任何一种解决方案都能为您提供帮助。

iOS 8 Snapshotting a view that has not been rendered results in an empty snapshot iOS 8快照未呈现的视图会导致快照为空

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM