Reproject image sources only if actually needed

This commit is contained in:
Petr Sloup
2015-09-09 11:49:00 +02:00
parent 3353eeb0c3
commit 5388f96551
2 changed files with 45 additions and 3 deletions
+14
View File
@@ -30,6 +30,12 @@ goog.require('ol.reproj.Triangulation');
ol.reproj.Image = function(sourceProj, targetProj,
targetExtent, targetResolution, pixelRatio, getImageFunction) {
/**
* @private
* @type {ol.proj.Projection}
*/
this.targetProj_ = targetProj;
/**
* @private
* @type {ol.Extent}
@@ -127,6 +133,14 @@ ol.reproj.Image.prototype.getImage = function(opt_context) {
};
/**
* @return {ol.proj.Projection} Projection.
*/
ol.reproj.Image.prototype.getProjection = function() {
return this.targetProj_;
};
/**
* @private
*/