From 8222b792212e4c66dd59032c3711ae917e0cce3c Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Mon, 5 Nov 2018 16:35:25 +0100 Subject: [PATCH] wip #2327 @0:10 --- js/libs/fluidbook/fluidbook.3dflip.js | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/js/libs/fluidbook/fluidbook.3dflip.js b/js/libs/fluidbook/fluidbook.3dflip.js index 5e7b4116..7cf59414 100644 --- a/js/libs/fluidbook/fluidbook.3dflip.js +++ b/js/libs/fluidbook/fluidbook.3dflip.js @@ -70,7 +70,7 @@ Fluidbook3DFlip.prototype = { if (performanceMode === undefined || performanceMode === 'auto' || performanceMode === 'performancesTest') { this.veryLowPerf = this.fluidbook.support.IE > 0 || this.fluidbook.support.iOS; - this.lowPerf = !Modernizr.webgl || this.veryLowPerf || this.fluidbook.support.edge || this.fluidbook.support.android || this.fluidbook.support.macOs; + this.lowPerf = !Modernizr.webgl || this.veryLowPerf || this.fluidbook.support.edge || this.fluidbook.support.android || this.fluidbook.support.macOs; } else if (performanceMode === 'lowPerf') { this.lowPerf = true; this.veryLowPerf = false; @@ -439,24 +439,32 @@ Fluidbook3DFlip.prototype = { }); } - var d = ((720 + this._pageRotation) % 360); - this.plane.rotation.y = d * this.deg2rad; - this.renderer.render(this.scene, this.camera); - this.modifier && this.modifier.apply(); + var render = true; if (this._progressAnimation < 1) { + if (this.turnRunning) { if (this.performancesTestRunning) { this.performancesFrames++; } + render = true; this.jcontainer.show(); } else { + render = false; this.jcontainer.hide(); } } else { + render = false; this.jcontainer.hide(); } + if (render) { + var d = ((720 + this._pageRotation) % 360); + this.plane.rotation.y = d * this.deg2rad; + this.renderer.render(this.scene, this.camera); + this.modifier && this.modifier.apply(); + } + if (this._callbackAfterNextRender !== null) { try { var c = this._callbackAfterNextRender; -- 2.39.5