Autodesk / Autodesk/revit-ifc

PR: IFC export skips opening cut when intersecting element is flush with wall top

Open
#985 1 comment 0 reactions 0 assignees View on GitHub
problem
Dominant language
C#
Stars
637
Forks
225
PR merge metrics
No merged PRs in 30d

Description

### Problem Description

**Revit Version:** 2026 (Build 26.4.0.32, DEU)
**IFC Exporter Version:** 26.4.1.0 (also reproduced with default built-in exporter)
**IFC Schema tested:** IFC2x3 and IFC4 — both affected identically

## Problem Description

When a structural framing element (beam) intersects a wall via Join Geometry, and the top of the intersecting element is set to exactly the same elevation as the top of the wall, the IFC exporter fails to generate an `IfcOpeningElement`/`IfcRelVoidsElement` for the intersection. The wall is instead exported as a single, complete, uncut `IfcExtrudedAreaSolid`, resulting in overlapping geometry in the IFC file (wall and beam solids fully overlap where they should be cut).

If the top of the wall is raised even 1 mm above the top of the beam, the opening is generated correctly.

This worked correctly in Revit 2025 (same model, same join). The regression appears specific to Revit 2026 / IFC Exporter 26.x.

## Steps to Reproduce

1. Create a wall (e.g. 240mm interior wall) and a structural beam (e.g. 300x600mm), positioned so the beam intersects the wall with Join Geometry active.
2. Set the top of the beam elevation to exactly equal the top of wall elevation.
3. Export to IFC (2x3 or IFC4, default settings).
4. Inspect the resulting wall's Body representation — it is exported as a full, uncut `IfcExtrudedAreaSolid`, with no associated `IfcOpeningElement`.
5. Raise the wall's top elevation by 1mm (or lower the beam by 1mm) so the two elevations no longer coincide exactly.
6. Re-export to IFC.
7. Inspect the wall again — it now correctly has an `IfcOpeningElement` via `IfcRelVoidsElement`, sized to match the beam's cross-section at the intersection.

## Evidence - see attached IFCs.

[IFCs.zip](https://github.com/user-attachments/files/29562597/IFCs.zip)

## Suspected Root Cause

This appears related to the opening-detection logic in the boolean/void generation path, likely in `GeometryUtil.cs`. There is an existing developer comment in that file noting that faces with normals parallel to the extrusion direction are more error-prone for boolean operations and suggesting these should instead be exported either as an `IfcOpeningElement` or as an inner boundary of the extrusion, flagged as "considered for a future improvement." When the intersecting element's boundary face is exactly coplanar with the wall's top face, the opening-detection appears to fail entirely rather than degrade gracefully — resulting in no cut being applied at all, rather than a partial/edge-flush opening.

## Expected Behavior

The wall should be cut (via `IfcOpeningElement`) at the intersection regardless of whether the intersecting element's boundary is flush with the wall's own boundary. At minimum, this should not silently produce a fully uncut, overlapping solid — since this was correctly handled in Revit 2025 with the same source geometry.

### Revit Version

2026.4.x

### IFC for Revit Addon Version

26.4.1

### Windows Version

11 25H2

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the reported IFC export with the attached IFCs.zip and compare the flush-elevation and 1 mm offset cases. Read the opening and boolean-generation path in GeometryUtil.cs, including its existing comment about faces parallel to the extrusion direction. Done means the flush case exports an IfcOpeningElement linked by IfcRelVoidsElement, without overlapping uncut wall and beam solids.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
computer-graphics
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.