Support different resolutions in x and y direction for ol.source.ImageStatic

This commit is contained in:
Bart van den Eijnden
2015-10-30 15:01:01 +01:00
parent 7f4c6e3634
commit 979342091a
13 changed files with 75 additions and 31 deletions
+5 -3
View File
@@ -24,7 +24,9 @@ ol.ImageState = {
* @constructor
* @extends {goog.events.EventTarget}
* @param {ol.Extent} extent Extent.
* @param {number|undefined} resolution Resolution.
* @param {Array.<number>|undefined} resolution Resolution, first value
* is the resolution in the x direction, second value is the resolution
* in the y direction.
* @param {number} pixelRatio Pixel ratio.
* @param {ol.ImageState} state State.
* @param {Array.<ol.Attribution>} attributions Attributions.
@@ -53,7 +55,7 @@ ol.ImageBase = function(extent, resolution, pixelRatio, state, attributions) {
/**
* @protected
* @type {number|undefined}
* @type {Array.<number>|undefined}
*/
this.resolution = resolution;
@@ -107,7 +109,7 @@ ol.ImageBase.prototype.getPixelRatio = function() {
/**
* @return {number} Resolution.
* @return {Array.<number>} Resolution.
*/
ol.ImageBase.prototype.getResolution = function() {
goog.asserts.assert(this.resolution !== undefined, 'resolution not yet set');