Source updates for new extent structure

This commit is contained in:
Tim Schaub
2013-09-03 17:50:33 -06:00
parent a670b7979c
commit 75cb19d7e1
9 changed files with 21 additions and 19 deletions

View File

@@ -154,10 +154,11 @@ ol.source.WMTS = function(options) {
options.extent : projectionExtent;
if (!goog.isNull(extent) && projection.isGlobal() &&
extent[0] === projectionExtent[0] &&
extent[1] === projectionExtent[1]) {
extent[0][0] === projectionExtent[0][0] &&
extent[1][0] === projectionExtent[1][0]) {
var numCols = Math.ceil(
(extent[1] - extent[0]) / (tileExtent[1] - tileExtent[0]));
(extent[1][0] - extent[0][0]) /
(tileExtent[1][0] - tileExtent[0][0]));
x = goog.math.modulo(x, numCols);
tmpTileCoord.z = tileCoord.z;
tmpTileCoord.x = x;