Rename ol.renderer.Layer#renderFrame to prepareFrame
This commit is contained in:
@@ -67,7 +67,7 @@ ol.renderer.canvas.ImageLayer.prototype.getTransform = function() {
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.renderer.canvas.ImageLayer.prototype.renderFrame =
|
||||
ol.renderer.canvas.ImageLayer.prototype.prepareFrame =
|
||||
function(frameState, layerState) {
|
||||
|
||||
var view2DState = frameState.view2DState;
|
||||
|
||||
@@ -120,7 +120,7 @@ ol.renderer.canvas.Map.prototype.renderFrame = function(frameState) {
|
||||
viewResolution < layerState.minResolution) {
|
||||
continue;
|
||||
}
|
||||
layerRenderer.renderFrame(frameState, layerState);
|
||||
layerRenderer.prepareFrame(frameState, layerState);
|
||||
|
||||
image = layerRenderer.getImage();
|
||||
if (!goog.isNull(image)) {
|
||||
|
||||
@@ -105,7 +105,7 @@ ol.renderer.canvas.TileLayer.prototype.getTransform = function() {
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.renderer.canvas.TileLayer.prototype.renderFrame =
|
||||
ol.renderer.canvas.TileLayer.prototype.prepareFrame =
|
||||
function(frameState, layerState) {
|
||||
|
||||
//
|
||||
@@ -137,12 +137,12 @@ ol.renderer.canvas.TileLayer.prototype.renderFrame =
|
||||
// or (3) the canvas tile range doesn't contain the required tile
|
||||
// range. This canvas tile range invalidation thing is related to
|
||||
// an optimization where we attempt to redraw as few pixels as
|
||||
// possible on each renderFrame call.
|
||||
// possible on each prepareFrame call.
|
||||
//
|
||||
// - If the canvas tile range has been invalidated we reset
|
||||
// renderedCanvasTileRange_ and reset the renderedTiles_ array.
|
||||
// The renderedTiles_ array is the structure used to determine
|
||||
// the canvas pixels that need not be redrawn from one renderFrame
|
||||
// the canvas pixels that need not be redrawn from one prepareFrame
|
||||
// call to another. It records while tile has been rendered at
|
||||
// which position in the canvas.
|
||||
//
|
||||
|
||||
@@ -340,7 +340,7 @@ ol.renderer.canvas.VectorLayer.prototype.handleLayerChange_ = function(event) {
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.renderer.canvas.VectorLayer.prototype.renderFrame =
|
||||
ol.renderer.canvas.VectorLayer.prototype.prepareFrame =
|
||||
function(frameState, layerState) {
|
||||
|
||||
// TODO: consider bailing out here if rendered center and resolution
|
||||
@@ -378,8 +378,8 @@ ol.renderer.canvas.VectorLayer.prototype.renderFrame =
|
||||
}
|
||||
|
||||
if (goog.isNull(tileGrid)) {
|
||||
// We should only get here when the first call to renderFrame happens during
|
||||
// an animation. Try again in the next renderFrame call.
|
||||
// We should only get here when the first call to prepareFrame happens
|
||||
// during an animation. Try again in the next prepareFrame call.
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user