From 32338efe325cb92c508e22201196da1f70d60a3d Mon Sep 17 00:00:00 2001 From: Jon Stroop Date: Tue, 3 Feb 2015 07:58:33 -0500 Subject: [PATCH 1/2] wasn't using canonical syntax --- src/iiiftilesource.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/iiiftilesource.js b/src/iiiftilesource.js index c3c1fcd5..ca755b9f 100644 --- a/src/iiiftilesource.js +++ b/src/iiiftilesource.js @@ -216,6 +216,7 @@ $.extend( $.IIIFTileSource.prototype, $.TileSource.prototype, /** @lends OpenSea levelHeight = Math.ceil( this.height * scale ), //## iiif region + tileSize, iiifTileSizeWidth, iiifTileSizeHeight, iiifRegion, @@ -227,7 +228,8 @@ $.extend( $.IIIFTileSource.prototype, $.TileSource.prototype, /** @lends OpenSea iiifQuality, uri; - iiifTileSizeWidth = Math.ceil( this.getTileSize(level) / scale ); + tileSize = this.getTileSize(level); + iiifTileSizeWidth = Math.ceil( tileSize / scale ); iiifTileSizeHeight = iiifTileSizeWidth; if ( this['@context'].indexOf('/1.0/context.json') > -1 || @@ -238,7 +240,7 @@ $.extend( $.IIIFTileSource.prototype, $.TileSource.prototype, /** @lends OpenSea iiifQuality = "default.jpg"; } - if ( levelWidth < this.tile_width && levelHeight < this.tile_height ){ + if ( levelWidth < tileSize && levelHeight < tileSize ){ iiifSize = levelWidth + ","; iiifRegion = 'full'; } else { @@ -256,6 +258,7 @@ $.extend( $.IIIFTileSource.prototype, $.TileSource.prototype, /** @lends OpenSea }); + function configureFromXml10(xmlDoc) { //parse the xml if ( !xmlDoc || !xmlDoc.documentElement ) { From edc04df5bd8955e1ac0f6378320b5ae0f5be236a Mon Sep 17 00:00:00 2001 From: Ian Gilman Date: Thu, 5 Feb 2015 09:12:27 -0800 Subject: [PATCH 2/2] Changelog for #586 --- changelog.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/changelog.txt b/changelog.txt index a68ba727..473b745f 100644 --- a/changelog.txt +++ b/changelog.txt @@ -3,6 +3,8 @@ OPENSEADRAGON CHANGELOG 1.2.2: (in progress) +* Corrected IIIF tile source to use canonical syntax (#586) + 1.2.1: * Added preserveOverlays option (#561)