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

Implicit Tiling (v1.1) missing subtrees / wrong lookup? #844

Open
phoenixbf opened this issue Nov 18, 2024 · 7 comments
Open

Implicit Tiling (v1.1) missing subtrees / wrong lookup? #844

phoenixbf opened this issue Nov 18, 2024 · 7 comments
Labels
bug Something isn't working

Comments

@phoenixbf
Copy link
Contributor

phoenixbf commented Nov 18, 2024

Hi all
I'm testing tilesets using the new V1.1 tiler by cesium ion and implicit tiling plugin (octree).
Everything basically works ok, except towards octree leaves (higher-res tiles) there appears random misses (eg. "TilesRenderer : Failed to load tile at url "subtrees/5/8/14/0.subtree") on *.subtree files, causing indeed some holes in the mesh on close inspection as they refine.

I initially thought it was something related to a corrupted zip downloaded from ion, but instead it seems the last bit of the subtree path is composed differently (e.g. instead of "2.subtree", a "0.subtree" is fetched, and so on... while the subfolders path is correct on both cesium viewer and 3DTilesRenderer).
As if the last part of the path has wrong subtree filename computed (maybe morton codes)?

This bug can be replicated with any sufficiently complex obj converted into tileset using v1.1 ion tiler.

I'll try to provide more details while I keep testing, and have a more indepth inspection ad the code if I find something

@phoenixbf phoenixbf added the bug Something isn't working label Nov 18, 2024
@gkjohnson
Copy link
Contributor

gkjohnson commented Nov 18, 2024

Thanks for the report!

This bug can be replicated with any sufficiently complex obj converted into tileset using v1.1 ion tiler.

Can you please provide a specific tile set that exhibits the issue? Also please follow the bug report template. Trying to accurately recreate your issue from just a description and no tile set or images is a lot of effort and guess work.

cc @AnthonyGlt

@phoenixbf
Copy link
Contributor Author

Indeed. We are preparing a dataset that exhibits the issue

@phoenixbf
Copy link
Contributor Author

phoenixbf commented Nov 19, 2024

Ok, so here is a sample dataset generated with cesium ion tiler v1.1 that exhibits the issue (the url can be referenced directly by other viewers)
https://explore100.cnr.it/collections/100/models/v1.1/tileset.json

here is also a visual reference of issue in 3DTRenderer
photo_2024-11-19_22-55-58

..and the same tileset in Cesium ion viewer:
photo_2024-11-19_22-56-06

UPDATE: same tileset also rendered in Unreal Engine 5, using Cesium plugin:
photo_2024-11-20_12-12-42

Both the folder structure and files are identical to the content hosted on cesium ion (no files corruption or whatsoever).
As described, it somehow messes the path/filename of subtrees (eg: TilesRenderer : Failed to load tile at url "subtrees/5/7/11/1.subtree") thus creating the holes (misses) on refinement

My very wild guess would be on something related to morton codes (?) used in subtrees, but I could be wrong

@gkjohnson
Copy link
Contributor

Thanks - I'm less familiar with this portion of the code. I'm hoping @AnthonyGlt may have some ideas at what may be going on otherwise we may need some help investigating.

@AnthonyGlt
Copy link
Contributor

@phoenixbf I've tried quickly your data. You could be right about the Morton index.
It could be link to the recent implementation of the Octree support. 🤔
I'll need to take a deeper look.

Thank you for this issue.

@phoenixbf
Copy link
Contributor Author

@AnthonyGlt could you point me to the specific part computing the subtree index? So we can try to look together

@AnthonyGlt
Copy link
Contributor

@phoenixbf I checked a little bit but in this end of year I wasn't really available, sorry for that.

My guess it's to look at the subtree object creation

Which is in this method

https://github.com/NASA-AMMOS/3DTilesRendererJS/blob/master/src/plugins/base/SUBTREELoader.js#L834

If it's the index the issue, it is calculated here:
const index = i * branchingFactor + j;

Hopefully it is helpful

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants