Skip to content

Commit

Permalink
turn off requestAnimationframe before viewing a new object
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhard-42 committed Sep 4, 2024
1 parent 7bb74c7 commit fa21830
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,11 @@
};

function showViewer(control, mode, containerId) {
if (window.viewer != null) {
window.viewer.hasAnimationLoop = false;
window.viewer.continueAnimation = false;
}

const container = document.getElementById(containerId);
container.innerHTML = ""
if (mode == "glass") {
Expand Down

0 comments on commit fa21830

Please sign in to comment.