ios - IOS 14图像渲染问题本机反应
解决方案
添加[super displayLayer:layer]后可以显示图像;如果 _currentFrame 是 nil 如果我理解正确的话, _currentFrame 应该是用于动画图像,所以如果它是静止图像,我们可以使用 UIImage 实现来处理图像渲染,不确定它是否是正确的修复。react-native/Libraries/Image/RCTUIImageViewAnimated.m
if (_currentFrame) {
layer.contentsScale = self.animatedImageScale;
layer.contents = (__bridge id)_currentFrame.CGImage;
} else {
[super displayLayer:layer];
}
推荐阅读
- javascript - React、Redux、Filepond
- php - 挂钩 call_user_func_array - 可能吗?
- go - 使用模块,新安装的包不能在项目中引用
- regex - 99 到 9999999 之间的数字正则表达式
- sql - 根据条件获取最大值
- python - 如何不断检查 JSON 文件是否在 Python 中更新?
- ios - 如何以编程方式在中心图像周围的圆圈中布局图像/视图
- javascript - Google Chrome 扩展和 document.getElementbyId().click()
- c++builder - Indy TFTP 服务器异常 EIdTFTPAllocationExceeded
- javascript - JS中可以带参数调用不带参数的函数吗?