You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the course of getting strange, very long paths, I found that Utils.mergeVertices isn't merging vertices within tolerance distance of each other:
This debugging image shows the navmesh with vertices randomly colored. The discontinuity shows up because nearby but distinct vertices aren't being merged.
Just before I hit the "Submit" button, I searched a bit more and found that this is just a manifestation of mrdoob/three.js#24621. It doesn't look like their mitigation was brought over. That said, I think I will use a rounding based approach before I hand over the BufferGeometry to three-pathfinding. All that said, I'm creating this issue in case anyone else runs into this.
Thank you for this and your other amazing three.js related libraries!
The text was updated successfully, but these errors were encountered:
Note that the newer implementation in three.js is not fully able to solve this situation either, though it does reduce the occurrences, see mrdoob/three.js#24621 (comment).
I've written a vertex merging implementation before that would avoid the issue entirely, I think, but it was very slow. I'm hesitant to drop that somewhat complex code into this project.
That said, I think I will use a rounding based approach before I hand over the BufferGeometry to three-pathfinding...
I think that's a great solution if it solves the problems for your meshes! Just note that you'll probably want to remove any vertex attributes other than position before doing this, so normals and UVs don't affect the merge.
I'd also be happy to review a PR upgrading Utils.mergeVertices to the newer approach in three.js, if that seems to be working better.
In the course of getting strange, very long paths, I found that
Utils.mergeVertices
isn't merging vertices withintolerance
distance of each other:This debugging image shows the navmesh with vertices randomly colored. The discontinuity shows up because nearby but distinct vertices aren't being merged.
Just before I hit the "Submit" button, I searched a bit more and found that this is just a manifestation of mrdoob/three.js#24621. It doesn't look like their mitigation was brought over. That said, I think I will use a rounding based approach before I hand over the
BufferGeometry
tothree-pathfinding
. All that said, I'm creating this issue in case anyone else runs into this.Thank you for this and your other amazing three.js related libraries!
The text was updated successfully, but these errors were encountered: