Abort rendering when WebGL context is lost
This commit is contained in:
@@ -541,6 +541,10 @@ ol.renderer.webgl.Map.prototype.renderFrame = function(frameState) {
|
|||||||
|
|
||||||
var gl = this.getGL();
|
var gl = this.getGL();
|
||||||
|
|
||||||
|
if (gl.isContextLost()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (goog.isNull(frameState)) {
|
if (goog.isNull(frameState)) {
|
||||||
if (this.renderedVisible_) {
|
if (this.renderedVisible_) {
|
||||||
goog.style.showElement(this.canvas_, false);
|
goog.style.showElement(this.canvas_, false);
|
||||||
|
|||||||
Reference in New Issue
Block a user