Skip to content

Commit

Permalink
now works in instance mode too
Browse files Browse the repository at this point in the history
  • Loading branch information
capGoblin committed Nov 3, 2023
1 parent 91d3454 commit 069989a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/image/image.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,8 @@ p5.prototype.saveCanvas = function() {
args.shift();
} else if (arguments[0] instanceof p5.Framebuffer) {
const framebuffer = arguments[0];
temporaryGraphics = createGraphics(framebuffer.width, framebuffer.height);
temporaryGraphics = this.createGraphics(framebuffer.width,
framebuffer.height);
temporaryGraphics.pixelDensity(pixelDensity());
framebuffer.loadPixels();
temporaryGraphics.loadPixels();
Expand Down

0 comments on commit 069989a

Please sign in to comment.