From d4332f27fbf7d409540e4b2c752fe413eb4ad683 Mon Sep 17 00:00:00 2001 From: Thomas FORGIONE Date: Mon, 6 Jul 2015 18:36:00 +0200 Subject: [PATCH] Corrected bug and avoid sending to DB when not necessary --- js/l3d/apps/prototype/interactive/main.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/js/l3d/apps/prototype/interactive/main.js b/js/l3d/apps/prototype/interactive/main.js index b73654b..b0fa99b 100644 --- a/js/l3d/apps/prototype/interactive/main.js +++ b/js/l3d/apps/prototype/interactive/main.js @@ -56,6 +56,9 @@ window.onbeforeunload = function() { init(); if (initMainScene !== L3D.initPeach && initMainScene !== L3D.initSponza) logfps(); +else + L3D.BD.disable(); + animate(); function logfps() { @@ -231,8 +234,8 @@ function onWindowResize() { previewer.domElement.height = container_size.height(); renderer.setSize(container_size.width(), container_size.height()); - cameras.forEach(function(camera) {camera.aspect = container_size.width() / container_size.height();}); - cameras.forEach(function(camera) {camera.updateProjectionMatrix();}); + cameras.forEach(function(camera) {camera.camera.aspect = container_size.width() / container_size.height();}); + cameras.forEach(function(camera) {camera.camera.updateProjectionMatrix();}); render(); }