saveWindow(path);
Save the current window into an image. Acts as a screenshot.
Arguments
path
The image path to write to.In this example, press the mouse to save a screenshot of the window.x
function setup()
createWindow(300, 300);
end
function draw()
circle(200, 200, 32);
fill(255, 50, 100);
square(200, 200, 32);
end
function mousePressed()
saveWindow("./screenshot.png");
end