We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
typeof this.pixels == undefined
1 parent c1e7900 commit b2e0dcbCopy full SHA for b2e0dcb
src/webgl/p5.RendererGL.js
@@ -624,7 +624,7 @@ p5.RendererGL.prototype.loadPixels = function() {
624
h *= pd;
625
//if there isn't a renderer-level temporary pixels buffer
626
//make a new one
627
- if (this.pixels === undefined) {
+ if (typeof this.pixels === 'undefined') {
628
this.pixels = new Uint8Array(
629
this.GL.drawingBufferWidth * this.GL.drawingBufferHeight * 4
630
);
@@ -672,7 +672,7 @@ p5.RendererGL.prototype.resize = function(w, h) {
672
this._setDefaultCamera();
673
}
674
//resize pixels buffer
675
- if (this.pixels !== undefined) {
+ if (typeof this.pixels !== 'undefined') {
676
677
678
0 commit comments