SCNCylinder diffuse.contents - 为半径和高度部分渲染不同的内容
SCNCylinder diffuse.contents - Render different contents for both radius and height sections
有什么方法可以为半径和高度部分呈现不同的内容
我正在尝试使用圆柱形对象并使用 SCMaterial 实例 diffuse.contents 在其上渲染图像
myCustomMaterial.diffuse.contents = UIImage(named: "image")
它在圆柱体上渲染此图像,但是在高度和渲染部分上渲染相同的图像。
我想在高度部分和半径部分渲染不同的图像。可能吗?
使用一系列材料。
let cylinder = SCNCylinder(radius: 1.0, height: 1.0)
let cylinderNode = SCNNode(geometry: cylinder)
let fillMurray = SCNMaterial()
fillMurray.diffuse.contents = UIImage(named: "fillmurray460x300")
let kitten = SCNMaterial()
kitten.diffuse.contents = UIImage(named: "kitten140")
cylinder.materials = [fillMurray, kitten]
有什么方法可以为半径和高度部分呈现不同的内容
我正在尝试使用圆柱形对象并使用 SCMaterial 实例 diffuse.contents 在其上渲染图像
myCustomMaterial.diffuse.contents = UIImage(named: "image")
它在圆柱体上渲染此图像,但是在高度和渲染部分上渲染相同的图像。
我想在高度部分和半径部分渲染不同的图像。可能吗?
使用一系列材料。
let cylinder = SCNCylinder(radius: 1.0, height: 1.0)
let cylinderNode = SCNNode(geometry: cylinder)
let fillMurray = SCNMaterial()
fillMurray.diffuse.contents = UIImage(named: "fillmurray460x300")
let kitten = SCNMaterial()
kitten.diffuse.contents = UIImage(named: "kitten140")
cylinder.materials = [fillMurray, kitten]