[ad_1]
I’ve an interactive globe constructed with SceneKit. The globe is a SCNNode and the dots that symbolize land are additionally SCNNodes and are kids of the globe. I need to add a customized view because the geometry for one of many kids of the globe. I understand how so as to add a node with a spherical geometry and alter its colour and so forth. Im unsure find out how to use a customized view (swift ui) for the geometry of a node.
let lowerCircle = SCNSphere(radius: dotRadius * 5)
lowerCircle.firstMaterial?.diffuse.contents = GenericColor(cgColor: UIColor.white.cgColor)
lowerCircle.firstMaterial?.lightingModel = SCNMaterial.LightingModel.fixed
let dotNode = SCNNode(geometry: lowerCircle)
dotNode.title = "NewYorkDot"
dotNode.place = textureMap[i].place
positions.append(dotNode.place)
dotNodes.append(dotNode)
[ad_2]