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

Model matrix not getting applied to tileset correctly #7036

Open
lilleyse opened this issue Sep 12, 2018 · 10 comments
Open

Model matrix not getting applied to tileset correctly #7036

lilleyse opened this issue Sep 12, 2018 · 10 comments

Comments

@lilleyse
Copy link
Contributor

lilleyse commented Sep 12, 2018

This bug goes back to at least 1.42.

The modelMatrix property seems to have some weird interaction with the ContextCapture tileset posted here. The tileset uses the CESIUM_RTC extension but is in local coordinates.

Default view at center of the Earth:
modelmatrix-right

With model matrix applied
modelmatrix

Debugging Sandcastle demo

The good thing is when upgrading the tileset with 3d-tiles-tools (links to the 2.0-tools branch) the tileset is correct. Also needs to be running on a branch that combines #7035 and #6805. Hopefully it is easy to track down.

modelmatrix-right2

scene

Debugging Sandcastle demo

@lilleyse
Copy link
Contributor Author

The reason for the bad positions in the second image is CESIUM_RTC applies its translation after the model matrix. Saw the same problem in here: #6755 (comment).

The summary here is CESIUM_RTC doesn't work well with model matrices that have rotation. Upgrading the tileset with 3d-tiles-tools, which changes CESIUM_RTC to RTC_CENTER, is the best fix.

@OmarShehata
Copy link
Contributor

Same issue in this forum thread, retiling with Cesium ion fixes it.

@engineerhe
Copy link

image
I can not upgrade my model , the problem as above

@engineerhe
Copy link

The reason for the bad positions in the second image is CESIUM_RTC applies its translation after the model matrix. Saw the same problem in here: #6755 (comment).

The summary here is CESIUM_RTC doesn't work well with model matrices that have rotation. Upgrading the tileset with 3d-tiles-tools, which changes CESIUM_RTC to RTC_CENTER, is the best fix.

image
I can not resolve it , the 3d-tiles-tools is not working properly

@OmarShehata
Copy link
Contributor

@engineerhe just to narrow down the issue here, can you confirm if tiling your source data with Cesium ion produces a tileset that works as expected?

@engineerhe
Copy link

@OmarShehata,Thanks for your patient answer,I followed the steps below to solve the problem.
Firstly,i use obj23dtiles tool tiling my data and generate 3dtiles.
Secondly , i use 3d-tiles-tools to upgrade tileset ,but it always reports an error which Binary gLTF version is not 1.
so,i want to know besides upgrading the tileset or retiling the tileset ,is there any other way to solve the problom?

@engineerhe
Copy link

@OmarShehata,i have solved it . Thanks!

@OmarShehata
Copy link
Contributor

@engineerhe can you describe what the solution was?

@engineerhe
Copy link

engineerhe commented Aug 27, 2019

Sorry, I didn't see the message until now.The solution is very sample , you just switch obj23dtiles tool into branch 2.0.

@lvfeijian
Copy link

Sorry, I didn't see the message until now.The solution is very sample , you just switch obj23dtiles tool into branch 2.0.
obj23dtiles the address https://github.com/engineerhe/objTo3d-tiles??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants