Three-bvh-csg: A library for performing fast CSG operations!

will confirm the drawRange issue then report on three js github (made a thread to discuss this)
update:- confirmed that gltfExported does not export drawRange and there are no plans to support it in the future

here’s how the meshes currently export , i think the geometry.groups case has not been fully implemented in GltfExporter

==========================================

Update

Made a custom solution , working good so far

sandbox is here bvh csg export - CodeSandbox

method breakdown

  • clone the evaluator result geometry
  • splice the geometry.groups array so it contains only one material’s groups in each geometry
  • use mergeGroups from BufferGeometryUtils to get the new geometry
  • make a new mesh with the new geometry correct material

these new meshes exports as it looks in gltf :partying_face:

amazing work with the library! even with all this extra logic it’s still runs smoothly/realtime ! :ok_hand:

3 Likes