diff --git a/src/webgl/p5.Shader.js b/src/webgl/p5.Shader.js index 5435814f2d..f67696a506 100644 --- a/src/webgl/p5.Shader.js +++ b/src/webgl/p5.Shader.js @@ -258,8 +258,9 @@ p5.Shader.prototype.updateTextures = function() { }; p5.Shader.prototype.unbindTextures = function() { - // TODO: migrate stuff from material.js here - // - OR - have material.js define this function + for (const uniform of this.samplers) { + this.setUniform(uniform.name, this._renderer._getEmptyTexture()); + } }; p5.Shader.prototype._setMatrixUniforms = function() {