My method for selecting geometry involves using the numbers on my keyboard, as shown below:
if(keyboard.pressed("1")){
obj = torus;
}
This allows me to toggle their visibility:
if(keyboard.pressed("a")){
THREE.SceneUtils.traverseHierarchy( obj, function ( obj ) { obj.visible = false; } );
}
Now, I am looking to make a visual distinction for the "selected geometry" by changing its material or color. How can I achieve that?