Is there any way to change the opacity/alpha of all hierarchy (branch) rather than per each mesh material?
No. You can, however, use object.traverse()
to set the opacity of an object's material and it's children.
mesh.traverse( function( node ) {
if( node.material ) {
node.material.opacity = 0.5;
node.material.transparent = true;
}
});
three.js r.56
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With