ios - 如何将实时图像加载到 UIImageView
问题描述
我正在尝试将实时图像加载到 aUImageView
中,但它被加载为静态图像。
这是我的代码:
if let stringLocal = Bundle.main.path(forResource: "Image_from _iOS", ofType: "jpg") {
self.displayImageView.image = UIImage(named: stringLocal)
}
有什么建议么?
解决方案
实时照片是 PHLivePhoto,而不是 UIImage。所以它在 PHLivePhotoView 中实时显示,而不是在 UIImageView 中。
推荐阅读
- r - 使用 ggplot 将数据线添加到 VAR HD 图表
- c# - 无法使用winscard.dll c#读取RFID卡USB
- ptv-vissim - PTV Vissim - 有没有办法改变静态 3d 对象的颜色?
- react-native - 在本机反应中创建一个专注于按钮或文本输入的对话框消息
- java - Eclipse/Maven - 无法更新索引并添加新的依赖项
- r - ggplot2-如何使用 facet_wrap 覆盖按组分隔的个人轨迹图的组平均值?
- css - 在固定位置 div 下方动态定位 div
- php - 在 Cpanel 上的 Laravel 项目中上传图片
- javascript - 单击和确认时更改按钮的颜色
- python - 在 Django 查询集中动态定义过滤器参数