Skip to content

Conversation

@Leguark
Copy link
Member

@Leguark Leguark commented Oct 7, 2025

TL;DR

Fixed a bug in the mesh indexing logic when converting meshes to subsurface format.

What changed?

Modified the meshes_to_subsurface method to correctly calculate the index offset when combining multiple meshes. Instead of using the maximum value in the current simplex array, the code now adds the number of vertices in each mesh to properly increment the index counter.

How to test?

Test the meshes_to_subsurface method with multiple meshes of different sizes to verify that the vertex indices are correctly offset and that no index overlapping occurs between different meshes.

Why make this change?

The previous implementation incorrectly calculated the index offset by using the maximum value in the current simplex array. This could lead to index overlapping or gaps when combining meshes with non-sequential vertex indices. The new approach ensures that indices are properly incremented based on the actual number of vertices in each mesh, resulting in correctly connected mesh structures.

@Leguark Leguark changed the title [BUG] Fix index updating in raw_arrays_solution to account for varying vertex counts across meshes [FIX] Correct vertex index calculation in meshes_to_subsurface method Oct 7, 2025
@Leguark Leguark changed the title [FIX] Correct vertex index calculation in meshes_to_subsurface method [FIX] Correct vertex index calculation in meshes_to_subsurface method | GEN-13443 Oct 7, 2025
@Leguark Leguark changed the title [FIX] Correct vertex index calculation in meshes_to_subsurface method | GEN-13443 [FIX] Correct vertex index calculation in meshes_to_subsurface method | GEN-13442 Oct 7, 2025
@Leguark Leguark marked this pull request as ready for review October 7, 2025 06:46
@Leguark Leguark changed the title [FIX] Correct vertex index calculation in meshes_to_subsurface method | GEN-13442 [FIX] Correct vertex index calculation in meshes_to_subsurface method | GEN-13490 Oct 9, 2025
Copy link
Member Author

Leguark commented Oct 9, 2025

Merge activity

  • Oct 9, 10:07 AM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Oct 9, 10:07 AM UTC: @Leguark merged this pull request with Graphite.

@Leguark Leguark merged commit b108542 into main Oct 9, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants