mirror of
https://github.com/openseadragon/openseadragon.git
synced 2024-11-22 05:06:09 +03:00
Documentation and © fix
This commit is contained in:
parent
cbdb0d19be
commit
8a6a111698
@ -6,6 +6,9 @@ OPENSEADRAGON CHANGELOG
|
||||
* Fix for IIPServer-style urls when using DZI (#413)
|
||||
* Fix memory leak while destroying the viewer (#421)
|
||||
* Added fitBoundsWithConstraints() to the viewport (#423)
|
||||
* New combined IIIF TileSource for 1.0 through 2.0 (#441)
|
||||
* Allowed TileSources to have dynamic tileSize via source.getTileSize(level) (#441)
|
||||
|
||||
|
||||
1.1.1:
|
||||
|
||||
|
@ -1,6 +1,7 @@
|
||||
/*
|
||||
* OpenSeadragon - IIIFMultiTileSource
|
||||
*
|
||||
* Copyright (C) 2009 CodePlex Foundation
|
||||
* Copyright (C) 2010-2013 OpenSeadragon contributors
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -42,7 +43,7 @@
|
||||
* @extends OpenSeadragon.TileSource
|
||||
* @see http://iiif.io/api/image/
|
||||
*/
|
||||
$.IIIFMultiTileSource = function( options ){
|
||||
$.IIIFTileSource = function( options ){
|
||||
|
||||
|
||||
$.extend( true, this, options );
|
||||
@ -107,7 +108,7 @@ $.IIIFMultiTileSource = function( options ){
|
||||
$.TileSource.apply( this, [ options ] );
|
||||
};
|
||||
|
||||
$.extend( $.IIIFMultiTileSource.prototype, $.TileSource.prototype, /** @lends OpenSeadragon.IIIFMultiTileSource.prototype */{
|
||||
$.extend( $.IIIFTileSource.prototype, $.TileSource.prototype, /** @lends OpenSeadragon.IIIFTileSource.prototype */{
|
||||
/**
|
||||
* Determine if the data and/or url imply the image service is supported by
|
||||
* this tile source.
|
||||
@ -148,7 +149,7 @@ $.extend( $.IIIFMultiTileSource.prototype, $.TileSource.prototype, /** @lends Op
|
||||
*
|
||||
* @function
|
||||
* @param {Object} data - the raw configuration
|
||||
* @example <caption>IIIF 1.1 Info Looks like this (XML syntax is no more)</caption>
|
||||
* @example <caption>IIIF 1.1 Info Looks like this</caption>
|
||||
* {
|
||||
* "@context" : "http://library.stanford.edu/iiif/image-api/1.1/context.json",
|
||||
* "@id" : "http://iiif.example.com/prefix/1E34750D-38DB-4825-A38A-B60A345E591C",
|
||||
@ -178,6 +179,12 @@ $.extend( $.IIIFMultiTileSource.prototype, $.TileSource.prototype, /** @lends Op
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
* Return the tileSize for the given level.
|
||||
* @function
|
||||
* @param {Number} level
|
||||
*/
|
||||
|
||||
getTileSize: function( level ){
|
||||
var scaleFactor = Math.pow(2, this.maxLevel - level);
|
||||
// cache it in case any external code is going to read it directly
|
||||
|
@ -127,6 +127,8 @@ $.TileSource = function( width, height, tileSize, tileOverlap, minLevel, maxLeve
|
||||
*/
|
||||
/**
|
||||
* The size of the image tiles used to compose the image.
|
||||
* Please note that tileSize may be deprecated in a future release.
|
||||
* Instead the getTileSize(level) function should be used.
|
||||
* @member {Number} tileSize
|
||||
* @memberof OpenSeadragon.TileSource#
|
||||
*/
|
||||
@ -195,6 +197,10 @@ $.TileSource = function( width, height, tileSize, tileOverlap, minLevel, maxLeve
|
||||
$.TileSource.prototype = /** @lends OpenSeadragon.TileSource.prototype */{
|
||||
|
||||
/**
|
||||
* Return the tileSize for a given level.
|
||||
* Subclasses should override this if tileSizes can be different at different levels
|
||||
* such as in IIIFTileSource. Code should use this function rather than reading
|
||||
* from .tileSize directly. tileSize may be deprecated in a future release.
|
||||
* @function
|
||||
* @param {Number} level
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user