Skip to content

Fix(rebar): use shell geometry if rebars are not exported as SweptDiskSolids#156

Open
MiguelG97 wants to merge 5 commits intoThatOpen:mainfrom
MiguelG97:main
Open

Fix(rebar): use shell geometry if rebars are not exported as SweptDiskSolids#156
MiguelG97 wants to merge 5 commits intoThatOpen:mainfrom
MiguelG97:main

Conversation

@MiguelG97
Copy link
Member

Fix #146

Description

This PR fixes how reinforcing rebars are loaded into fragments when they aren’t exported as SweptDiskSolid. if a rebar doesn’t have a valid directrix axis, it falls back to loadShellGeometry so it still shows up in the scene.

Additional context

Before, the code assumed all IFCREINFORCINGBAR geometries had a SweptDiskSolid with a directrix. But some IFC exports (like from Tekla) might be configured to export rebars as IfcFacetedBrep, which doesn’t have that data. That made loadCircleExtrusionGeometry fail and the rebars wouldn’t load.

rebars.not.rendering.mov

Now, this change checks if the sweep directrix exists and uses the shell loader if it doesn’t, so all rebars get parsed and rendered correctly.

rebars.rendering.mov

What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

Before submitting the PR, please make sure you do the following:

  • Check that there isn't already a PR that solves the problem the same way to avoid creating a duplicate.
  • Follow the Conventional Commits v1.0.0 standard for PR naming (e.g. feat(examples): add hello-world example).
  • Provide a description in this PR that addresses what the PR is solving, or reference the issue that it solves (e.g. fixes #123).
  • Ideally, include relevant tests that fail without this PR but pass with it.

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.

rebars (IfcReinforcingBar) not rendered when loading Fragments (latest versions)

1 participant