Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

312
Views
CLOSE - How to merge mesh in THREE.js (r128)

what I want to do is the following, I create a custom shape voxel and I want to merge the different custom voxels into a single one. I try with:

let geom = new THREE.BufferGeometry();

for(let i = 0; i < scene.children.length; i++){
        if(scene.children[i].name === "custom-voxel"){
                geom.merge(scene.children[i].geometry);
        }
}

But it doesn't work so I try with:

var geometries = [];
for(let i = 0; i < scene.children.length; i++){
        if(scene.children[i].name === "custom-voxel"){
                geometry.push(scene.children[i].geometry.clone());
        }
}

geom = mergeBufferGeometries(geometries);
geom.computeBoundingBox();
var meshh = new THREE.Mesh(
        geom,
        new THREE.MeshBasicMaterial({ color: 0x0000ff })
);

But in this way it also doesn't work or better it create the all object in the same position, do you have an idea on how I can keep the distance between objects?

Thanks.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!