Fix reality data not being reprojected correctly when its CRS is different than iModel (backport #9059) [release/5.7.x]#9075
Merged
Conversation
…erent than iModel (#9059) Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> Co-authored-by: Ben Polinsky <78756012+ben-polinsky@users.noreply.github.com> Co-authored-by: Anmol Shrestha <98850418+anmolshres98@users.noreply.github.com> (cherry picked from commit d122ee6) # Conflicts: # docs/changehistory/NextVersion.md
Contributor
Author
|
Cherry-pick of d122ee6 has failed: To fix up this pull request, you can check it out locally. See documentation: https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/reviewing-changes-in-pull-requests/checking-out-pull-requests-locally |
eringram
approved these changes
Mar 9, 2026
Contributor
|
@copilot resolve merge conflict using the conflict resolver skill |
Closed
4 tasks
Contributor
NextVersion.md kept empty for release branch. The reality data CRS reprojection fix entry is placed under Display > Fixes in 5.7.0.md. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
There is a bug where when using the reproject parameter of
TileTreeReference.createGeometryTreeReference, if the reality data is not in the same CRS than the iModel, the reprojection will put the geometry at the wrong place.This was because in
RealityTileLoader.loadGeometryFromStream, the geometry returned byRealityTileLoader.readGltfAndCreateGeometryis in iModel coordinates, but the reprojection transform is in the reality tree's coordinates.The fix is to take this difference into account by doing the following:
iModelTransformto "convert" polyface from iModel CRS->tile tree CRSxFormiModelTransformto convert back from tile tree CRS->iModel CRSTested with a couple different iModels with reality data in different CRS. I also added some unit tests for this.
This is an automatic backport of pull request #9059 done by Mergify.