Skip to content

fix(saved-mesh): close planar edges at used trim stations (#2250), carrying #2256 - #2296

Merged
DrunkOnJava merged 3 commits into
mainfrom
fix/2256-planar-stations
Dec 6, 2026
Merged

DrunkOnJava merged 3 commits into
mainfrom
fix/2256-planar-stations

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Dec 6, 2026 •

Copy link
Copy Markdown
Owner

Summary

Saved planar faces now split a one-sided triangle edge at a collinear trim station, even when another triangle already uses that station, so the face closes without a T-junction. On the BIM4LCA and Revit 2025 models, walls (IfcWall) gain Height, GrossSideArea, GrossVolume and their net values, beams (IfcBeam) their surface areas, volumes and CrossSectionArea, and proxies their NetVolume, each moving from missing to equal to Revit's; no value moves to different. No body changes its source: the only field that moves in any diagnostics.json is total_entities. This carries shifatrHtH's #2256 onto current main: their two commits, cherry-picked onto current main and re-signed with them as author, plus the changelog credit. The cherry-pick merged native_saved_mesh.rs automatically, since #2276 to #2280 have changed it since #2256's base. Supersedes #2256.

Closes #2250.

Motivation

#2250: a complete saved mesh in RE1 Mechanical has three one-sided edges. Earcut uses a boundary station in one triangle but leaves a longer edge through it in the neighbouring one, and the existing boundary restoration treats an already-used station as restored. The branch rules require signed commits, which #2256's two aren't.

Changes

  • src/research/native_saved_mesh.rs (shifatrHtH): conform_used_planar_stations splits a one-sided edge at each used boundary station within 1e-10 ft of it, keeping the authored vertex positions, the winding and a nonzero area, or else keeps the validated triangles. Its checks count against the face's PLANAR_WORK_BUDGET, with a pair limit of 1,000,000 shared across its rings.
  • probes/examples/probe_2250_planar_boundary_stations.rs and tools/re/replay_planar_boundary_stations.py (shifatrHtH): a public RE1 Mechanical probe and a two-binary replay.
  • changelog.d/fixed/planar-boundary-stations.md, with "Contributed by shifatrHtH."

Testing

Breaking changes

None.

Co-authored-by: shifatrHtH 342213537+shifatrHtH@users.noreply.github.com

shifatrHtH and others added 3 commits December 6, 2026 02:32
Earcut can use a boundary station in one triangle and leave a longer one-sided edge through it. Split the incident triangle at the stored station while preserving vertex positions and winding.

Refs #2250.
@DrunkOnJava
DrunkOnJava merged commit b8f19df into main Dec 6, 2026
38 checks passed
@DrunkOnJava
DrunkOnJava deleted the fix/2256-planar-stations branch December 6, 2026 08:50
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.

Saved planar triangulation leaves T-junctions at already-used boundary stations

2 participants