Skip to content

Commit

Permalink
Fix erase and noErase in webgl
Browse files Browse the repository at this point in the history
  • Loading branch information
acamposuribe committed Nov 3, 2023
1 parent 8f3fea9 commit 0df9212
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/webgl/p5.RendererGL.js
Original file line number Diff line number Diff line change
Expand Up @@ -1198,7 +1198,7 @@ p5.RendererGL = class RendererGL extends p5.Renderer {
// It's necessary to restore post-erase state. Needs rework
let temp = this.curBlendMode;
this.blendMode(this._cachedBlendMode);
this._cachedBlendMode = temp; // If we don't do this, appleBlendMode() returns null
this._cachedBlendMode = temp; // If we don't do this, applyBlendMode() returns null
this._isErasing = false;
this._applyBlendMode(); // This sets _cachedBlendMode back to the original blendmode
}
Expand Down

0 comments on commit 0df9212

Please sign in to comment.