Fix geodesic remesh: correct percent units, enable geodesics on remeshed surface, skip wasted precompute.#2557
Merged
Conversation
…hed surface, skip wasted precompute. Mesh::remeshPercent expects a 0–1 fraction; the two optimize call sites passed the raw project value (e.g. 10) which inflated meshes ~10× instead of reducing to 10%. ACVD then ran for minutes on the bloated mesh, and for some input geometries overshot the target by another 1.65×. The remeshed Surface was also constructed with the default geodesics_enabled=false, so compute_distance/is_within_distance silently fell back to Euclidean during optimization — masking the slowness as "runs fast" while producing non-geodesic correspondence. Meanwhile the full-resolution main Surface ran precompute_geodesics it never needed. ParticleNeighborhood and Sampler keyed weighting/euclidean decisions off the main surface's flag; with the precompute moved off the main surface, they now go through a new MeshDomain::is_geodesics_enabled() accessor that asks the canonical geodesics surface.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mesh::remeshPercent expects a 0–1 fraction; the two optimize call sites passed the raw project value (e.g. 10) which inflated meshes ~10× instead of reducing to 10%. ACVD then ran for minutes on the bloated mesh, and for some input geometries overshot the target by another 1.65×.
The remeshed Surface was also constructed with the default geodesics_enabled=false, so compute_distance/is_within_distance silently fell back to Euclidean during optimization — masking the slowness as "runs fast" while producing non-geodesic correspondence. Meanwhile the full-resolution main Surface ran precompute_geodesics it never needed.
ParticleNeighborhood and Sampler keyed weighting/euclidean decisions off the main surface's flag; with the precompute moved off the main surface, they now go through a new MeshDomain::is_geodesics_enabled() accessor that asks the canonical geodesics surface.