TileCache.js uses math.floor instead of math.round like TC does.
Thanks Brent. (Closes #1261) git-svn-id: http://svn.openlayers.org/trunk/openlayers@5745 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -103,8 +103,8 @@ OpenLayers.Layer.TileCache = OpenLayers.Class(OpenLayers.Layer.Grid, {
|
|||||||
var res = this.map.getResolution();
|
var res = this.map.getResolution();
|
||||||
var bbox = this.maxExtent;
|
var bbox = this.maxExtent;
|
||||||
var size = this.tileSize;
|
var size = this.tileSize;
|
||||||
var tileX = Math.floor((bounds.left - bbox.left) / (res * size.w));
|
var tileX = Math.round((bounds.left - bbox.left) / (res * size.w));
|
||||||
var tileY = Math.floor((bounds.bottom - bbox.bottom) / (res * size.h));
|
var tileY = Math.round((bounds.bottom - bbox.bottom) / (res * size.h));
|
||||||
var tileZ = this.map.zoom;
|
var tileZ = this.map.zoom;
|
||||||
/**
|
/**
|
||||||
* Zero-pad a positive integer.
|
* Zero-pad a positive integer.
|
||||||
|
|||||||
Reference in New Issue
Block a user