From fd59701ee3d420909e4ef7cb6276f7b469a6753c Mon Sep 17 00:00:00 2001 From: Brian Peiris <brianpeiris@gmail.com> Date: Tue, 10 Apr 2018 13:06:54 -0700 Subject: [PATCH] add some delay to allow environments to render --- src/hub.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/hub.js b/src/hub.js index 6d9223d33..6c6d9fc89 100644 --- a/src/hub.js +++ b/src/hub.js @@ -255,8 +255,8 @@ const onReady = async () => { const initialEnvironmentEl = document.createElement("a-entity"); initialEnvironmentEl.addEventListener("bundleloaded", () => { uiRoot.setState({ initialEnvironmentLoaded: true }); - // Wait a tick so that the environments actually render. - setTimeout(() => scene.renderer.animate(null)); + // Wait a tick plus some margin so that the environments actually render. + setTimeout(() => scene.renderer.animate(null), 100); }); environmentRoot.appendChild(initialEnvironmentEl); -- GitLab