Repository navigation
fix(research): a plane that meets a cylinder along an edge across both its parameters is meshed, and 175 elements of the 2024 samples are drawn from their saved meshes (#1706) (RE-426) - #1709
Conversation
…at the refusals of the plane's refinement would need to accept (#1706) Counts, by curved kind, the plane-to-curved edges that run along u, along v or along neither; for the last, the samples per edge, the chord's sagitta against the curved surface at a pair of samples' parameter midpoint, the distance of that surface point from the plane, and whether the curved face meshes.
…h its parameters is meshed, the edge refined to the bar by its own points (#1706) refined_plane_edge refused every shared edge that is not along u or v of the curved face (a slanted plane through a cylinder is an ellipse in its parameters), which kept 141 elements of Snowdon Towers Architectural as record boxes. An edge across both parameters now takes the points of the edge itself (Newton's method onto the plane at the middle of the parameter that changes more, halving to 2.5e-4 ft of chord sagitta), on the plane's polygon and on the cylinder's loop alike. Any other edge is as before.
…ope stays out of its loop (#1706) The 24 railings of Snowdon Towers Architectural that were refused for a shared edge that changes its fixed parameter came out refused for 'cylinder trim outside envelope': the envelope is made from the samples and the edge between two of them can lie a sagitta beyond it. The loop keeps the graph's samples there; the plane's polygon keeps the point.
…edge draws against Revit's export, and the 24 railings among them (#1706) (RE-426)
…crossing edges a plane meets a cylinder along (#1706) (RE-426)
|
Rows for the unfiltered run 43007950335 (head
|
…alving is refused, the solved parameter must lie between the samples', and the plane's polygon leaves out the points beyond the cylinder's envelope that its loop does (#1706) (RE-426)
|
Rows for the next unfiltered run, registered before it is dispatched (head
|
…tself, a point farther from the chord's middle than the chord is long is the other branch, and an edge that never settles is refused (#1706) (RE-426)
|
Head moved again, before the next runs: Row 3 therefore reads: the 24 railings are drawn on |
…ge's refinement are tested through limits passed in, each refused with its own message (#1706) (RE-426)
|
Why |
|
Registered before the run (time and memory of this change; the checklist line "Not a performance change" was a claim, not a measurement, and the exports grow by 1% to 33% (Measure 43018413566,
Run: Measure |
…offices and the held-out files, and what the meshes cost in size, time and memory (#1706) (RE-426) The unfiltered run of the final head moves 38 of 126 exports, not the 16 models of the kept exports: 25 railings in each of four BIM4LCA offices (24 of 25 within 1% of Revit's volume), the other releases of Autodesk's samples, 2 railings in four held-out files. The exports that draw more are 1% to 19% larger (Snowdon Towers Architectural 196.6 to 229.7 MB), and export time stays within 4% and peak memory within 3% of main's on one runner (rows T1 and T2 held).
# Conflicts: # changelog.d/changed/1706-crossing-edges.md # docs/format-reconnaissance.md # reports/element-framing/RE-426-crossing-edges.md
…ers, or has holes, is meshed in the cells of its grid, and 119 elements of Snowdon Towers Architectural and 43 of each office are drawn from their saved meshes (#1706) (RE-430) (#1715) ## Summary A ruled, revolved or cone face whose trim is not the rectangle of its parameters, or has holes, is meshed in the cells of its grid, where it was refused (`nonrectangular parametric trim`, `multiple parametric trim loops unsupported`). An element refused only for that is drawn from its saved mesh in place of a box: its BodySource `partition_element_record_bbox` (or `partition_family_instance_turned_box`) becomes `saved_graphics_mesh`, `body_sources` and `saved_mesh_refusals` in the diagnostics move by the same count, and the body becomes a triangulated face set, which makes the IFC larger. What moves (Measure, 126 exports against `main`: 101 identical, 25 differ): `IfcFurniture` (chairs, tables), `IfcSanitaryTerminal` (toilets, sinks, a faucet), `IfcCovering`, 2 `IfcBeam`, 1 `IfcRailing` per `rac_advanced` save and an `IfcSpace`. Snowdon Towers Architectural 119, each BIM4LCA office 43, the four large housing exports 15 and the two terrain ones 9, `rac_advanced` 71 per save, `rac_basic` 1, Snowdon Plumbing 13 and Structural 2, RE1 Architecture 1. Triangles drawn from saved graphics rise (the office at permit 838,380 to 1,590,622; Snowdon Architectural 5.17 to 6.23 million) and so do the IFCs: Snowdon Architectural 229.7 to 269.4 MB (+17.3%), the offices +27.8% to +31.2%, `rac_advanced` +53% to +56%, `rac_basic` +8.6%. ## Motivation The second step of #1706, after #1709. Snowdon Towers Architectural had 146 elements refused for the two reasons above. The cost is the finding too: 4,600 to 17,500 triangles per element drawn, where Revit's export of the same toilet has 1,668 (#1737). ## Changes - `trimmed_cells` and `tessellate_trimmed` (`src/research/native_parametric_mesh.rs`) cut the region the loops enclose into the grid's strips and cells; `keep_triangle` (pure, tested for its failures first) drops a triangle without area when its edges are all 1e-4 ft or shorter or its shortest is 1e-8 ft or shorter, and refuses a needle. - `tools/re/ifc_body_diff.py` and `tools/re/cut_ifc.py` (the tools the report's numbers come from), `reports/element-framing/RE-430-trimmed-faces.md`, the reconnaissance addendum and `changelog.d/changed/1706-trimmed-faces.md`. ## Testing Measure, unfiltered with `keep_ifc`: [43041839803](https://github.com/DrunkOnJava/rvt-rs/actions/runs/43041839803) (code `ea9a16d7`, kept at `refs/archive/2026-11-11/cited/ea9a16d7705e`, against `main` `8ec2ac98`); `timing` [43041844475](https://github.com/DrunkOnJava/rvt-rs/actions/runs/43041844475). The same-project gates pass. No element drawn at `main` changes: of 81,529 drawn on both sides in the 24 exports whose IFC was kept, 0 meshes differ, and every BodySource that changes is a box becoming a saved mesh. Against Revit's export (176 of the new elements are in it): 73 have the volume within 1%, the 102 chairs read 1.0164 (Revit draws their tubes as inscribed polygons), and no body has every vertex of Revit's within 0.001 ft (Revit's vertices lie up to 0.005 ft from the surface, on both sides). Export time 0.98 to 1.09 and peak memory 0.95 to 1.06 of `main`'s over 74 files. Rows 3, 4 and 9 registered on #1706 are missed and reported as measured in section 7 of RE-430. Refs #1706
… steps and at the v of the trim's own steps and cusps, and the triangles of 25 of 126 exports fall (#1737) (RE-437) (#1769) ## Summary A face cut by its trim is cut across at the chord's `v` steps and at the `v` of the trim's own steps and cusps, where `trimmed_cells` cut each strip's trapezoids at every knot of `v` and `face_grid` made every trim point's `v` a knot, so that a trim of T points left every trapezoid that held a point's `v` cut once more across the whole face. The strips keep a knot at every trim point's `u` (a trim segment must cross a strip whole, so each corner of the trim is still a corner of the cells). The cuts across them are now the chord's steps and the `v` of each vertex the trim does not run through from one strip to the next (`trim_steps`: the ends of a step along a strip boundary and the tip of a hole), because without those a strip's cells run straight past a vertex of the next strip's and leave a crack inside the face. A face meshed on its grid keeps every trim point as a knot on both axes, and a plane face that shares an edge with a cut face follows the same `v` knots (`refined_plane_edge`). No element stops being drawn from its saved mesh (BodySource changes 0). What moves (Measure, 126 exports against `main`: 101 identical, 25 differ, the same 25 as the first version of this change): the triangles from saved graphics fall by 7.5% on the BIM4LCA office (all 107,887 of them in its 43 toilets, a toilet from 14,025 to 11,516), 6.8% on Snowdon Towers Architectural, 4.6% on the four large housing exports, 3.3% on the two terrain ones and 10.4% on `rac_advanced`; the IFCs by 0.4% to 6.6% (the office 117.1 to 113.6 MB, Snowdon Towers Architectural 272.1 to 257.6 MB). The cracks are identical per class to `main`'s on the office as built (160 in 57 face sets), the timber office (168 in 57), the housing and RE1, none in a toilet, and fewer on `rac_advanced` (394 to 374). One measured negative: RE1 Architecture's shower head has its farthest vertex from Revit's surface move from 0.009123 to 0.01007 ft, over the 0.01 ft column of its class. ## Motivation #1737, the second lever of the density RE-430 measured (after RE-435): a toilet's two trimmed faces were 4,147 of its 14,025 triangles. A first version cut at the chord's steps alone and took 8.1% off the office, and rvtDevelop's read counted what its rows had not: the vertices of a face's cells inside a boundary edge of the same face's cells went from 160 to 504 on the office as built, the 344 more all in the 43 toilets. This version keeps the cuts that stop them and the diagnostic is in RE-437. ## Changes - `face_grid` (`src/research/native_parametric_mesh.rs`): the trim points' coordinates join the knots of `u`; for a face not meshed on its grid the knots of `v` take the `v` of the trim's steps and cusps (`trim_steps`) and no longer every trim point's; `trimmed_cells` no longer asks a trim point's `v` to be a knot (a point off the `u` knots is refused as before). Four failure-first tests of the pure helpers: a trim point between the `v` knots is a corner and not a cut, a point on a vertical side between them is covered all the same, the vertices a strip beside passes by are the steps and the cusps (an L, a diamond, a square with a diamond hole), and a step of the trim is a vertex of the strips on both sides when its `v` is a knot while chord steps alone leave a free edge off the trim. - `tools/re/mesh_tjunctions.py` (new): the crack count, per class of the owning product, over a kept export. - `reports/element-framing/RE-437-trimmed-face-cuts.md`, the reconnaissance addendum, `changelog.d/changed/1737-trimmed-face-cuts.md`, and the sentence of `changelog.d/changed/1706-trimmed-faces.md` that said every trim point was a knot. ## Testing The measured commit is `70bef87acfbe` (`ee2d9dfe`, the steps rule, merged over `main` `a0c1c61a`), archived as `refs/archive/2026-11-11/cited/70bef87acfbe`; the commits after it change the report, the fragments, the addendum and this description, and no source. - [x] Unfiltered Measure with `keep_ifc` ([43091480051](https://github.com/DrunkOnJava/rvt-rs/actions/runs/43091480051), against `main` `a0c1c61a`; GitHub's artifact outage of 2026-11-11 failed the uploads of 8 shards, which `gh run rerun --failed` re-ran as attempt 2) and `timing` ([43091485302](https://github.com/DrunkOnJava/rvt-rs/actions/runs/43091485302)). Rows registered on #1737 before the run ([comment 6805810741](#1737 (comment))) all hold: rows 1, 2, 4, 5 and 6 outright; row 3 on its registered columns (against Revit's export no class's median volume moves, and the counts within 1% of its volume and with every vertex of Revit's within 0.001 ft fall on no class), with the shower head's 0.01 ft column as a measured negative (RE-437 section 4); row 6: export time 0.97 to 1.02 and peak memory 0.98 to 1.05 of `main`'s (1.05 asked), the office 1.00 in both. - [x] The first version, Measure [43078686248](https://github.com/DrunkOnJava/rvt-rs/actions/runs/43078686248) (code `aafa5b1a`, kept under `refs/archive/2026-11-11/cited/aafa5b1a2f15`), held its five rows and left 344 cracks in the toilets: kept as the negative result in RE-437 section 2. - [ ] `same-project gates` and the semantic check on the measured commit; `full / CI passed` on the final head ## Audit-honesty checklist - [x] A user-visible change has its entry as a fragment under `changelog.d/changed/`. - [x] A reverse-engineering finding has its report: `reports/element-framing/RE-437-trimmed-face-cuts.md` (status, artefact hashes by run, measured counts, reproduce commands naming a commit). - [x] No emojis, no private paths in committed files. ## Legal and contribution hygiene - [x] Apache-2.0. No Autodesk proprietary source, internals or NDA material. - [x] No new test fixtures. ## Breaking changes None. ## Related issues Refs #1737 (the chord, the third lever, stays open). Follows #1715, #1744, #1709.
Summary
A plane face that meets a cylinder along an edge running across both of the cylinder's parameters (a slanted plane through a cylinder, a mitred rail) is meshed, where
refined_plane_edgerefused it ("shared curved edge is not an isoparametric interval" or "shared curved edge changes its fixed parameter"). An element refused only for that reason is drawn from its saved mesh in place of a box: its BodySourcepartition_element_record_bbox(partition_beam_box_along_axisfor a beam) becomessaved_graphics_mesh, its extruded box becomes a solid,bounding_box_bodiesfalls andbody_sources.saved_graphics_meshrises by the same count, and the body'sprovenance.value_sourcesentry (reader selected_frame, rule selected) becomes reader saved_graphics, rule native.What moves (Measure 43018413566, 126 exports against
main: 88 identical, 38 differ):saved_mesh_refusalsin the diagnostics): in the concrete offices 2 IfcSanitaryTerminal ("unsupported faceted topology"), in every office 1 further element ("unsupported surface HermiteSurf"), in re1-architecture 2 elements ("disconnected UV boundary", and "disconnected UV boundary; nonrectangular parametric trim"), in rac_basic 1 IfcSanitaryTerminal ("multiple parametric trim loops unsupported"), in Snowdon 19.Motivation
The first step of #1706. After #1683, 141 elements of Snowdon Towers Architectural were refused for a shared edge
refined_plane_edgewould not follow (116shared curved edge is not an isoparametric interval, 25shared curved edge changes its fixed parameter; 145 name one of the two). The probe (Measure 42998375045) reads what the edges are: 648 plane-to-cylinder edges run across both parameters, 484 within 0.001 ft of the surface by the graph's own samples and 164 not; the edges of ruled and revolved faces sit on faces refused for their trims, which is the next step.Changes
src/research/native_saved_mesh.rs:refine_crossing_edge(pure; between two samples the parameter that changes more is held at its middle value, the other found by Newton's method to 1e-9 ft of the plane, and the chord is judged against that point of the edge itself: where it is more than 0.00025 ft from the chord it is put between them, to 32 halvings; a point farther from the chord's middle than the chord is long, a span above the bound at the limit and an edge of more than 100,000 points are errors),isoparametric_axis,refined_curved_edge(the cylinder's loop takes the plane's points),within_envelope(both the loop and the plane's polygon leave out the points beyond the cylinder's envelope, so they hold one list), and thirteen failure-first tests of the pure helpers that check the refined chords against the true edge from the formula.tools/re/bodies_across_saves.pyandtools/re/readers_across_saves.py: two pins that shrink, as their lists allow (the first unfiltered run failedsame-project gateson them): rst_basic's 9 beam boxes are saved meshes, and rac_advanced's roof 201262 on 2026 and 2027 leavesROOFS_NOT_THE_2025_BODY(its mesh is the 2025 save's body to the census's bar).probes/examples/probe_1706_shared_edges.rs: the edges between a plane and a curved face, by kind.reports/element-framing/RE-426-crossing-edges.md, the addendum indocs/format-reconnaissance.mdandchangelog.d/changed/1706-crossing-edges.md.Testing
Measured on the Measure runner, no local build. Rows were registered on #1706 (comment 6792974651) and on this PR (comment 6793985827) before the runs; the report (section 7) reads each.
Unfiltered run 43018413566 (
dce5241f, 126 exports, againstmain5cf94975):same-project gatespassed; 88 exports identical, 38 differ as the Summary lists.bounding_box_bodiesfalls by the countsaved_graphics_meshrises, in every model.rvt-ifc.log): Snowdon Architectural 196.6 -> 229.7 MB (+16.8%); permit office 87.7 -> 95.9 MB (+9.3%; saved-graphics triangles 680,612 -> 838,380); rac_advanced 2024 45.5 -> 53.6 MB (+17.8%), every release +18% to +20%; rme 98.7 -> 99.9 and 104.7 -> 105.8 MB (+1.1% to +1.2%); rac_basic +1.3%; rst_basic +4.2% to +4.4%; terrain housing +1.2%; terrain offices 0.9 -> 1.2 MB (+32%). Time and memory (Measure 43020958270, both builds on one runner, three rounds, 26 files; rows T1 and T2 of comment 6795860731): export time head over base 0.99 to 1.04 (Snowdon Architectural 41.5 s to 42.4 s) and peak memory 0.97 to 1.03 (Snowdon Architectural 1,399 MiB on both sides), so both rows held.82b5ad32547f2f27keep_ifccylinder trim outside envelopeea1f01fdkeep_ifc, 16 models674a55b3mainsame-project gatesfailed on five pins that expected the old state (rst_basic 2025 to 2027, rac_advanced 2026 and 2027); no body differedf59e822dkeep_ifc, 2024 samplesdce5241fkeep_ifc, 2024 samplesdce5241fmain5cf94975, gate scripts from the branchsame-project gatespassed; the figures abovedce5241ftiming, 2024 samples, offices, reference modelsThe call on the railings (the maintainer's; on the record for review). Row 3 said that on a miss the step narrows to the edges whose chords the samples already hold. It was looked at and is not what Snowdon's railings miss: their chords are within 0.00025 ft by construction, the 101 railings drawn at
mainwithout a crossing edge read the same (34 within 1%, median 1.1758), and the scorer's shell reading explains 1,792 of the 1,937 shells of 22 of them as Revit's inscribed polygons of fewer sides. Railing 622056, read in full, has Revit's vertices on rvt-rs's mesh wherever Revit draws a bar, and where Revit draws 44.9 degrees of a corner's arc as one chord rvt-rs's mesh follows the arc to 0.00004 ft. Narrowing would return 24 railings to boxes about a thousand times Revit's volume (#1635). The 145 shells the scorer cannot read (bars cut at a slant) are #1712. The offices' 25 railings per file (22 of one design within 0.5%) and the held-out files' 2 (1.2152) show the same split by design of the bars.tools/check-local.sh: no local build here; the PR's own CI runs fmt, clippy, rustdoc, the test matrix and--lib(the six tests of the pure helper)Audit-honesty checklist
changelog.d/changed/1706-crossing-edges.md)Legal and contribution hygiene
Breaking changes
None to the API. 38 of the 126 exports of Measure 43018413566 differ, as the Summary lists, and the other 88 are byte-identical; the exports that differ are larger (Testing, Cost).
Related issues
Refs #1706 (step 2, the nonrectangular parametric trim, remains), #1635, #1712.