Add ol.tilegrid.TileGrid.getTileCoordChildTileRange
This commit is contained in:
@@ -164,6 +164,21 @@ ol.tilegrid.TileGrid.prototype.getResolutions = function() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param {ol.TileCoord} tileCoord Tile coordinate.
|
||||||
|
* @return {ol.TileRange} Tile range.
|
||||||
|
*/
|
||||||
|
ol.tilegrid.TileGrid.prototype.getTileCoordChildTileRange =
|
||||||
|
function(tileCoord) {
|
||||||
|
if (tileCoord.z < this.resolutions_.length) {
|
||||||
|
var tileCoordExtent = this.getTileCoordExtent(tileCoord);
|
||||||
|
return this.getTileRangeForExtentAndZ(tileCoordExtent, tileCoord.z + 1);
|
||||||
|
} else {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {number} z Z.
|
* @param {number} z Z.
|
||||||
* @param {ol.TileRange} tileRange Tile range.
|
* @param {ol.TileRange} tileRange Tile range.
|
||||||
|
|||||||
Reference in New Issue
Block a user