Hello! I have an STL model that is a set of faces with face normals but I’d like to smooth them. Right now my process is to remove the existing normals, merge the geometry vertices and then run “computeVertexNormals” but that has the undesired effect of smoothing the “hard edges”, as well. Think a cyclinder geometry where you want to smooth the caps and body of the geometry without smoothing the hard end edges.

Here’s an old code pen (three.js r86) but it’s only built for the legacy Geometry class: codepen.

For a cylinder geometry I achieve the desired result using a stock LatheGeometry and duplicating the path vertices where I want hard edges. This may be a hack, but for LatheGeometries it trips the ‘computeVertexNormal’ algorithm in the desired way.

A cylinder is just a simple demonstration case. As I mentioned I have an STL file that is basically just a soup of triangles that I need to remerge the vertices for.

My question isn’t about whether or not it’s possible - I know it is. I provided a demonstration above working for the old THREE.Geometry. And I’ve written algorithms like this myself previously.

What I’m asking for is whether or not one has already been written so I don’t have to look into building on myself.

The key words here are merge vertices as indicated in your question. By doing so, there is a high chance that you will end up with messed up uvs, normal and other attributes that depend on overlapping vertices.