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

Ability to force refetch of existing virtual tour node #1450

Closed
AnonymousSausage77 opened this issue Oct 3, 2024 · 2 comments
Closed

Ability to force refetch of existing virtual tour node #1450

AnonymousSausage77 opened this issue Oct 3, 2024 · 2 comments
Labels
Milestone

Comments

@AnonymousSausage77
Copy link

AnonymousSausage77 commented Oct 3, 2024

Describe the feature

I need a way to force PSV to re-fetch a node when using Virtual Tour. Currently, I have changed the data of a virtual tour node and want to refetch it without changing which node is currently being looked at, but neither:

tour.setCurrentNode(nodeId)
nor
tour.init();
nor
viewer.needsUpdate();
trigger a refetch of the existing node.

For example, let's say i have changed the direction of the virtual tour links (arrows) of currently-viewed virtual tour node, or perhaps I have changed the offset of the pano image, if I want to force a refetch to update the current node's configuration I don't believe there is a way to do this without deleting and re-initialising the entire viewer (let me know if there is!).

Maybe something like:

      tour.setCurrentNode(nodeId, {
        forceUpdate: true, // refetches the node regardless of if nodeId has changed or not
      })

would be cool.

Alternatives you've considered

Until this point, I was recreating the entire viewer; I was calling destroy on PSV and then recreating it with the updated settings to trigger a refetch of all settings. This had its own issues, including a webgl context overflow and is just inefficient.

Additional context

I need this because the pano viewer is acting as a frontend to give users the ability to preview their changes in real time.

I am using:

  • EquirectangularTiles
  • VirtualTour plugin (server-side fetching)
@AnonymousSausage77 AnonymousSausage77 changed the title Ability to refetch existing virtual tour node Ability to force refetch of existing virtual tour node Oct 3, 2024
@mistic100 mistic100 added this to the 5.10.2 milestone Oct 3, 2024
Copy link

This feature/bug fix has been released in version 5.11.0.

@mistic100
Copy link
Owner

@AnonymousSausage77 please check #1460 (comment) this might be a better solution

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