[英]SceneKit Floor Texture Changed Color in Xcode 8
I have a floor in my SceneKit scene that is suppose to be green based on the texture I have selected for its diffuse property.我的 SceneKit 场景中有一个地板,根据我为其漫反射属性选择的纹理,假设它是绿色的。 It worked perfectly in Xcode 7, however, in Xcode 8 it is red and shows up on my device as gray.
它在 Xcode 7 中运行良好,但是,在 Xcode 8 中它是红色的,在我的设备上显示为灰色。 Here are some screenshots below that help explain this better:
以下是一些有助于更好地解释这一点的屏幕截图:
Any and all help is great appreciated.非常感谢任何和所有帮助。
I suppose this is because your image has a single color channel and SceneKit handles it a R8 texture.我想这是因为您的图像具有单个颜色通道,而 SceneKit 将其处理为 R8 纹理。 Try converting it to RGB (what SceneKit was doing in iOS 9/Xcode7 anyway).
尝试将其转换为 RGB(无论如何 SceneKit 在 iOS 9/Xcode7 中所做的)。 And please file a bug.
并请提交错误。
I recently came across with the same problem and fixed that issue with using JPEG file instead PNG.我最近遇到了同样的问题,并通过使用 JPEG 文件而不是 PNG 解决了该问题。 That might be related with a bug in xCode 8
这可能与 xCode 8 中的错误有关
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.