gkjohnson / three-bvh-csg

A flexible, memory compact, fast and dynamic CSG implementation on top of three-mesh-bvh
MIT License
552 stars 45 forks source link

Add utility for simplifying flat mesh surfaces #96

Open gkjohnson opened 1 year ago

gkjohnson commented 1 year ago

During the process of applying CSG to a mesh flat surfaces become unnecessarily complex. During lulls in user operation it would be good to remesh brushes so they use a minimal number of triangles while still being connected - ie retriangulate flat / coplanar surfaces.

Alternative:

TODO:

johncalvinyoung commented 1 year ago

For a variety of use cases, it'd be good to make this a purely optional part of the workflow--I have applications where retaining the position & connectivity of any un-changed vertices is mildly important

gkjohnson commented 1 year ago

Possibly related:

https://github.com/mrdoob/three.js/issues/10517