alecjacobson / gptoolbox

Matlab toolbox for Geometry Processing.
MIT License
628 stars 166 forks source link

remove_duplicate_vertices does not use the epsilon parameter as significant digit #81

Closed rarora7777 closed 4 years ago

rarora7777 commented 5 years ago

The input description for mesh/remove_duplicate_vertices.m suggests that epsilon is the "uniqueness tolerance (significance digit)". However, the current behaviour of the function does not comply with this definition.

Changing line 52 to this should do the trick: [~,SVI,SVJ] = unique(round(V*(10^epsilon)),'rows','stable');

alecjacobson commented 4 years ago

Fixed in f584ecd, but note that documentation changed so the epsilon is clearly a fractional input (and removed the 10*