ios - adding a border around SceneKit node -


i trying highlight selected node in scenekit tap gesture. unfortunately, have not been able accomplish it. best thing change material when node tapped.

let material = key.geometry!.firstmaterial! material.emission.contents = uicolor.blackcolor() 

can suggest way can go add border or outline around object instead of changing color of entire node?

scnnode conforms scnboundingvolume protocol.

this protocol defines getboundingboxmin:max: method.

use minimum , maximum coordinates of bounding box of geometry attached node.

then use scenekit primitive type scngeometryprimitivetypeline draw lines of bounding box. check scngeometryelement.


Comments

Popular posts from this blog

android - can not access to progress bar in an other activity -

Lists in Python -

java - Vaadin 7 Pass Data Between Views -