Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drape model map layers onto reality models #7637

Merged
merged 116 commits into from
Mar 25, 2025
Merged

Conversation

markschlosseratbentley
Copy link
Contributor

@markschlosseratbentley markschlosseratbentley commented Jan 31, 2025

This PR adds support to iTwin.js for draping model map layers onto reality data.

A new property titled drapeTarget has been added to ModelMapLayerProps and ModelMapLayerSettings. When this property is specified as ModelMapLayerDrapeTarget.RealityData, the model map layer will be only draped onto all attached reality data. Supported reality data formats include glTF or b3dm. If drapeTarget is not specified in the properties, it will default to ModelMapLayerDrapeTarget.BackgroundMap, which will only drape the model map layer onto the background map.

TODO:

TODO (Future PRs):

Here is an example of draping a model from within an iModel (the piping in the air) onto some glTF reality data (the terrain underneath):
image

Here is an example of the same dataset as above with the model itself disabled, so you only see the draping onto the glTF reality data:
image

To test locally, you can open display-test-app and:

  • open an iModel
  • attach a reality model located somewhere near the iModel
  • utilize the keyin fdt attach model maplayer reality while an element is selected - the model associated with that element will drape onto the reality model.

@markschlosseratbentley

This comment was marked as resolved.

@CLAassistant

This comment was marked as resolved.

@danielzhong-bentley

This comment was marked as resolved.

@pmconne

This comment was marked as resolved.

@markschlosseratbentley markschlosseratbentley changed the title Drape map layer imagery onto reality models Drape model map layers onto reality models Feb 10, 2025
@markschlosseratbentley
Copy link
Contributor Author

For now, we planned to explicitly advertise support for B3DM and glTF (the testcases we have). We believe glTF will be the most common use case.

I would just not mention formats and just refer to draping on reality models. i3dm isn't useful for reality models and cmpt is rare outside of tests.

References to specific formats have been removed.

Copy link
Contributor

mergify bot commented Mar 21, 2025

This pull request is now in conflicts. Could you fix it @markschlosseratbentley? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

@danielzhong-bentley danielzhong-bentley enabled auto-merge (squash) March 25, 2025 14:47
@danielzhong-bentley danielzhong-bentley merged commit cdceef4 into master Mar 25, 2025
16 checks passed
@danielzhong-bentley danielzhong-bentley deleted the drape-onto-reality branch March 25, 2025 15:23
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.

6 participants