You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to display a frame for an object on the panorama and change its position and transformation via matrix3d depending on the panorama position.
If I use viewer.setUpdate(true), then the frame does not move at all, and if without viewer.setUpdate, then the frame moves only after the movement is completed.
I can't use the custom hotspot from the examples because I want to apply matrix3d transformation.
What is the correct event to use for movement?
How to make a transformation with animation?
The viewer.setUpdate() method is for handling dynamic content as the panorama input. This is for supporting, e.g., <video> and <canvas> elements as input. This only works for equirectangular images, not multires like you're using, and it's irrelevant for anything that isn't the panorama image source, anyway.
then the frame moves only after the movement is completed
What did you expect was going to happen? The documentation for the animatefinished event states that it fires "when any movements / animations finish, i.e. when the renderer stops rendering new frames". As per the documentation, it fires when the movement stops, not during the movement.
If I use viewer.setUpdate(true), then the frame does not move at all
Normally, the viewer doesn't render new frames when there's no movement, since that would be wasteful as nothing is changing. To support dynamic content, the viewer has to render new frames even when the view is stationary. Since the viewer continues to render frames, the animatefinished event isn't fired. This is arguably a bug, since it breaks the intent of the event (although it's not relevant for what you're trying to do), but it is consistent with the documentation.
What is the correct event to use for movement?
There is currently no such event. This is tracked by #310 (comment), which I should really revisit at some point but have not gotten around to. There I discuss a render event, although it's probably better to also have a viewchanged event, to better handle the nuances of dynamic content.
Hello.
I want to display a frame for an object on the panorama and change its position and transformation via matrix3d depending on the panorama position.
If I use viewer.setUpdate(true), then the frame does not move at all, and if without viewer.setUpdate, then the frame moves only after the movement is completed.
I can't use the custom hotspot from the examples because I want to apply matrix3d transformation.
What is the correct event to use for movement?
How to make a transformation with animation?
Here is an example of code:
The text was updated successfully, but these errors were encountered: