Fix maxLevel typo

This commit is contained in:
Sanghoon Kim 2021-12-01 10:01:18 +09:00
parent 24d5d98548
commit 7686812336

View File

@ -306,8 +306,8 @@ $.TileSource.prototype = {
// a memoized re-implementation // a memoized re-implementation
var levelScaleCache = {}, var levelScaleCache = {},
i; i;
for( i = 0; i <= this.maxlevel; i++ ){ for( i = 0; i <= this.maxLevel; i++ ){
levelScaleCache[ i ] = 1 / Math.pow(2, this.maxlevel - i); levelScaleCache[ i ] = 1 / Math.pow(2, this.maxLevel - i);
} }
this.getLevelScale = function( _level ){ this.getLevelScale = function( _level ){
return levelScaleCache[ _level ]; return levelScaleCache[ _level ];