diff --git a/src/accessibility/gridOutput.js b/src/accessibility/gridOutput.js index f5b4936cd5..cbeb03ae50 100644 --- a/src/accessibility/gridOutput.js +++ b/src/accessibility/gridOutput.js @@ -10,6 +10,14 @@ import p5 from '../core/main'; //updates gridOutput p5.prototype._updateGridOutput = function(idT) { + // Check if the current rendering mode is WEBGL + if (this._renderer && this._renderer instanceof p5.RendererGL) { + if (!this._didOutputGridWebGLMessage) { + this._didOutputGridWebGLMessage = true; + console.error('gridOutput() does not yet work in WebGL mode.'); + } + return; + } //if html structure is not there yet if (!this.dummyDOM.querySelector(`#${idT}_summary`)) { return; diff --git a/src/accessibility/textOutput.js b/src/accessibility/textOutput.js index 1fe2dc8137..bc3a7b3134 100644 --- a/src/accessibility/textOutput.js +++ b/src/accessibility/textOutput.js @@ -10,6 +10,14 @@ import p5 from '../core/main'; //updates textOutput p5.prototype._updateTextOutput = function(idT) { + // Check if the current rendering mode is WEBGL + if (this._renderer && this._renderer instanceof p5.RendererGL) { + if (!this._didOutputTextWebGLMessage) { + this._didOutputTextWebGLMessage = true; + console.error('textOutput() does not yet work in WebGL mode.'); + } + return; + } //if html structure is not there yet if (!this.dummyDOM.querySelector(`#${idT}_summary`)) { return;