Repository navigation
feat(elements): name walls, floors, ceilings, roofs and railings with their system-family type (#322) (RE-44) - #341
Merged
Conversation
… their system-family type (#322) (RE-44) A system-family type has no RE-38 name entry, but its serialised element data opens with ff ff ff ff, a per-release u16 (0x02d3 on 2024, 0x02ef on 2025), 01 00 00 00 and the type's id, and the first framed string after that is its name. The element's type is the RE-28 type record its reference list names; type records are now read on Revit 2025 and as second-prologue frames. Every TypeName written equals Revit's on Core Interior (460), Snowdon Towers (1,545), RE1 Architecture (16) and Projeto1 (1); on teste_export_2025 six of seven, the seventh being a wall that export shows in a later state of the model.
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_6883d004-722b-498b-8af7-3bd31db3648e) |
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.
Summary
Walls, floors, ceilings, roofs and railings now carry their type's name as
TypeName, the same name Revit gives them. A system-family type has no RE-38 name entry. Its name is in its own serialised element data, and the element's type comes from the RE-28 type records. Both are now read on Revit 2024 and 2025.Motivation
Closes #322. After RE-38, every family instance had Revit's
Family:Typename, but walls, floors and other system-family elements had no type name at all. For the people using rvt-rs, a wall's type ("8" Interior Partition 3 Hour") is the first thing they look for.Changes
src/partition_names.rs:element_data_header(release)(0x02d3on 2024,0x02efon 2025) andfind_element_data_names. The name is the first framed string after the header and the type id. A frame whose length is unset, a control character or a noncharacter is skipped, and an id whose copies disagree is dropped.src/partition_type_records.rs:decode_at_with_marker/find_type_records_with_marker: the marker is the last six bytes of the release's bbox marker, and the magic isrecord_prologue_constant.src/partition_schema_mvp.rs:attach_system_type_namesfor walls, slabs and products that have no RE-38 names yet.src/ifc/export_content.rs:TypeNameis written whenever a type name is known.FamilyNameis written only with a family.examples/probe_re44_system_type_names.rs,reports/element-framing/RE-44-system-type-names.md, a reconnaissance addendum, a support-matrix row (element-record-system-type-names, partial), and updates to README, status and CHANGELOG.research/witness/magnetar-2024-core-interior{,-slim}/observations/rvt-rs.json: regenerated for the 460 newIfcPropertySingleValue. Both verdicts still PASS.Testing
tools/check-local.sh --corpus: fmt, clippy-D warnings, rustdoc-D warnings, workspace tests with both corpora.cargo +1.85.0 check --profile ci --all-targets(MSRV) andcargo +nightly check --manifest-path fuzz/Cargo.toml: clean. The let-chain scan is empty.tests/element_names.rs:core_interior_system_type_names_are_revits: 360 walls, 99 floors and the pad, each equal to Revit'sObjectTypetype half.re1_system_type_names_are_revits: Revit 2025; 8 walls, 2 floors named-and--, 6 ceilings.tests/fixtures/synthetic-project.ifcis unchanged. The Core export differs from the released 0.2.0rvt-ifconly by 460IfcPropertySingleValueand their property sets. Otherwise only the owner-history timestamp and 14 positional relationship GlobalIds differ.Measured against Revit's own exports (the type half of
ObjectType, same Tag):teste_export_2025(local only)The one difference is oracle drift, not a decoder miss. Wall 327589's frame reference list, its serialised data and its record bounding box all describe type 398 (200 mm). Its data is byte-identical to that of wall 327728, which Revit exports as 200 mm. Its box also differs from Revit's IFC geometry by 42 mm and 27 mm, while its neighbours match to 0.1 mm. So that export was made after the wall was changed to 300 mm. Report §5.
Audit-honesty checklist
TypeNameonly: the IFCNamestaysClass-ElementIdand noObjectType,FamilyNameorIfcWallTypeis written, because the family name ("Basic Wall", "Parede básica" in the Portuguese export) is not in the file.Legal and contribution hygiene
RVT_PROJECT_CORPUS_DIR; nothing is vendored.Breaking changes
None against 0.2.0.
partition_type_records::decode_second_prologue_atandpartition_names::find_element_data_namesare new in this PR.decode_atandfind_type_recordskeep their 2024 signatures, and*_with_markervariants are added.Related issues
Closes #322. Follow-ups found on the way (report §7):
IfcCoveringType/CLADDINGonteste_export_2025).IfcWall.Note
Medium Risk
Touches partition byte parsing, MVP element recovery, and IFC property emission on real 2024/2025 projects; impact is mitigated by fail-closed decoding and corpus-backed tests, but exported IFC property sets change for affected elements.
Overview
Walls, floors, ceilings, roofs, and railings now get their system-family type name on export (#322, RE-44). Names are parsed from each type’s serialized partition element data (release-specific header + first framed UTF-16 string), joined to instances via existing RE-28 type-definition records, and written as
TypeNameon the element property set. Loadable families still use RE-38;FamilyNameis emitted only when a family exists—the UI system-family label (e.g. “Basic Wall”) is not stored in the file, so IFCName/ObjectTypestay unchanged and noIfcWallTypeentities are added.Partition type-record decoding is extended to Revit 2025 (marker/prologue from the release bbox marker) and second-prologue type frames that inherit the enclosing partition record’s ElementId (RE-35). New probe
probe_re44_system_type_names, CI checks intests/element_names.rs, and docs/support-matrix/witness updates; Core Interior witness gains 460IfcPropertySingleValuerows for the new properties.Reviewed by Cursor Bugbot for commit f98e17f. Configure here.