In an attempt to find a solution, I've shared details about this issue on my personal blog since I can only include limited links in this post as a newbie on Stack Overflow.
Since my initial inquiry, I have provided updates to showcase the progress made so far.
You can witness my code in action through this link, along with the crucial segments below:
var side = this.data.side; // The default value should be 2, and all I want to do is alter material.side to side;
var object3D = this.el.object3D;
console.log("Commencing traversal of object3D");
object3D.traverse( function( child ){
console.log("Traversing...")
console.log("Current child object: ", child);
console.log("Child type", typeof child);
if ( child instanceof THREE.Group ) {
console.log("THREE.Group found!")
child.traverse(function(childOfChild) {
console.log("Further traversing...")
console.log("Current child of child object: ", childOfChild);
console.log("Child type", typeof childOfChild);
if ( childOfChild instanceof THREE.Mesh ) {
console.log("THREE.Mesh found!")
}
}
);
}
}
);
console.log("Traversal of object3D complete");
My main goal is simple:
To change theMaterialOfTheObject3D.side to 2 also known as THREE.DoubleSide
But the real challenge lies in accessing the material within Three.js. Traversal seems impossible as per @mrdoob’s statement:
Geometries and Materials are not children.