Two years later, the question came back to me

I am not a 3D major, just an amateur.
This is a two-year problem. Could you help me solve it?

  1. How do you create a wall with window?

  2. When I use CSG to successfully create the windowless wall, will the material of the new wall be misplaced?

const geometry = new THREE.BoxGeometry(wallWidth, wallDepth, wallHeight);
const material = new THREE.MeshBasicMaterial({color: wallColor});
const wall = new THREE.Mesh(geometry, material);
scene.add(wall);

will the material of the new wall be misplaced?

Depends on the CSG library, but it shouldn’t be.

1 Like

Thank you for your reply and I am sorry that I wrote the wrong question.
I want to build a wall with a window, but after I use CSG, the material of the wall is confused, so I would like to ask if there is any way to solve this problem? Or is there another way to build it?

Can you share you code? If possible as a live example on codesandbox or codepen.

This post was flagged by the community and is temporarily hidden.

This post was flagged by the community and is temporarily hidden.