From 97d388be7ddf933d24d385e2e7a25ceeb0d35e53 Mon Sep 17 00:00:00 2001 From: Michael Gibson Date: Fri, 28 Feb 2025 11:30:30 -0700 Subject: [PATCH] Add loadTilesOnAnimationPath flag --- src/tiledimage.js | 7 ++++++- src/viewer.js | 1 + 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/tiledimage.js b/src/tiledimage.js index 10055e0d..3d670062 100644 --- a/src/tiledimage.js +++ b/src/tiledimage.js @@ -176,6 +176,7 @@ $.TiledImage = function( options ) { wrapHorizontal: $.DEFAULT_SETTINGS.wrapHorizontal, wrapVertical: $.DEFAULT_SETTINGS.wrapVertical, immediateRender: $.DEFAULT_SETTINGS.immediateRender, + loadTilesOnAnimationPath: $.DEFAULT_SETTINGS.loadTilesOnAnimationPath, blendTime: $.DEFAULT_SETTINGS.blendTime, alwaysBlend: $.DEFAULT_SETTINGS.alwaysBlend, minPixelRatio: $.DEFAULT_SETTINGS.minPixelRatio, @@ -1354,7 +1355,11 @@ $.extend($.TiledImage.prototype, $.EventSource.prototype, /** @lends OpenSeadrag var highestLevel = levelsInterval.highestLevel; // the highest level we should draw at our current zoom var bestTiles = []; var drawArea = this.getDrawArea(); - var loadArea = this.getLoadArea(); + var loadArea = drawArea; + + if (!this.loadTilesOnAnimationPath) { + loadArea = this.getLoadArea(); + } var currentTime = $.now(); // reset each tile's beingDrawn flag diff --git a/src/viewer.js b/src/viewer.js index 5d2d52bc..023da35b 100644 --- a/src/viewer.js +++ b/src/viewer.js @@ -1748,6 +1748,7 @@ $.extend( $.Viewer.prototype, $.EventSource.prototype, $.ControlDock.prototype, wrapHorizontal: _this.wrapHorizontal, wrapVertical: _this.wrapVertical, maxTilesPerFrame: _this.maxTilesPerFrame, + loadTilesOnAnimationPath: _this.loadTilesOnAnimationPath, immediateRender: _this.immediateRender, blendTime: _this.blendTime, alwaysBlend: _this.alwaysBlend,