Clear context when source revision changed
This is to avoid rendering artifacts when making a layer invisible, changing its source's PARAMS, and making the layer visible again.
This commit is contained in:
@@ -234,7 +234,8 @@ class CanvasTileLayerRenderer extends IntermediateCanvasRenderer {
|
||||
canvas.width = width;
|
||||
canvas.height = height;
|
||||
} else {
|
||||
if (this.renderedExtent_ && !equals(imageExtent, this.renderedExtent_)) {
|
||||
if ((this.renderedExtent_ && !equals(imageExtent, this.renderedExtent_)) ||
|
||||
this.renderedRevision != sourceRevision) {
|
||||
context.clearRect(0, 0, width, height);
|
||||
}
|
||||
oversampling = this.oversampling_;
|
||||
|
||||
Reference in New Issue
Block a user