I am generating an SKTexture with a GKNoiseMap. When I look at the texture in a swift playground, it has the expected colours. But when I apply the texture to a material and render it in a SCNView, the colours are different (colours appear too bright). What am I doing wrong?
Wrong colours when rendering SKTexture
Too bright ?
How does this translate in color rob and alpha ?
Use Digital color meter to compare both.
How does this translate in color rob and alpha ?
Use Digital color meter to compare both.
I've noticed this as well and filed a bug report to Apple exactly 6 months ago, still without answer. It is easily reproducible with this code:
let url = Bundle.main.url(forResource: "art.scnassets/texture.png", withExtension: nil)!
plane1.firstMaterial!.diffuse.contents = url.path
let node1 = SCNNode(geometry: plane1)
node1.position.x = -5
scene.rootNode.addChildNode(node1)
let plane2 = SCNPlane(width: 10, height: 10)
plane2.firstMaterial!.diffuse.contents = SKTexture(image: NSImage(byReferencing: url))
let node2 = SCNNode(geometry: plane2)
node2.position.x = 5
scene.rootNode.addChildNode(node2)
I've noticed this as well and filed a bug report to Apple
What was your bug number?
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"
Since this issue is still happening 3 years later on macOS 14.6.1, I stumbled again on this post and I see only now that you asked for the bug number, but unfortunately I didn't subscribe to this post back then and wasn't notified of your reply. It's FB8979522.