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

3Dtiles issue when 2 view are created #2426

Closed
AnthonyGlt opened this issue Oct 4, 2024 · 2 comments
Closed

3Dtiles issue when 2 view are created #2426

AnthonyGlt opened this issue Oct 4, 2024 · 2 comments
Assignees
Labels

Comments

@AnthonyGlt
Copy link
Contributor

AnthonyGlt commented Oct 4, 2024

I have 2 itowns view loaded on the same page.
On each view, I'm loading a 3dtiles dataset.
I have to wait for the 3dtiles from the first view to finish loading before seeing the tiles from the second view.
Also, when I switch from one view to the other, the 3dtiles disappear and starts requesting all the tiles again.

Context

Manage 2 view with 3dtiles in each

Steps to Reproduce

  1. Create 2 views with 2 3dtile dataset
  2. Interact with each view
  3. Observe that the whole dataset disappear before reloading completely
Screencast.from.04-10-2024.15.11.49.webm

Possible Cause/Fix/Solution

Looks like it's caused by:

_setupCacheAndQueues() {

@jailln
Copy link
Contributor

jailln commented Oct 4, 2024

We indeed share the 3D tiles cache, download and parse queues among all tilesets.

With this new use case in mind, one solution would be to share them per view. To do so, we could:

  • Add an id property to View
  • Declare a Map of 3DTilesRendererJS with the view id as key and lruCache, downloadQueue and parseQueue as value.
  • Take care of filling this map and setting up the cache and queues in OGC3DTilesLayer._setup (that is called by View.addLayer(3DTilesLayer))

That would have the advantages to manage 3DTiles independently for each view and to take care of this setup for our users (which in many cases won't want to deal with this kind of stuff I think). I also can't think of any usecase where one would want to share the same cache and queues amongst views.

WDYT @AnthonyGlt @Desplandis ?

@jailln
Copy link
Contributor

jailln commented Nov 8, 2024

Done in #2435

@jailln jailln closed this as completed Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants