diff --git a/src/core/shape/attributes.js b/src/core/shape/attributes.js index b88ab13afd..210d54271d 100644 --- a/src/core/shape/attributes.js +++ b/src/core/shape/attributes.js @@ -176,7 +176,10 @@ p5.prototype.noSmooth = function() { this.drawingContext.imageSmoothingEnabled = false; } } else { - this.setAttributes('antialias', false); + // Only change if necessary to prevent canvas recreation + if (this._renderer.attributes.antialias !== false) { + this.setAttributes('antialias', false); + } } return this; };