Take a screenshot of the current scene. The function either displays the screenshot in a new browser window or returns the image as a base64-encoded string.
Demo
Custom file prefix:
Take a screenshot. The image data is returned as base64-encoded string.
Save a screenshot as PNG file.
Save a screenshot as JPEG file with default quality.
Save a screenshot as JPEG file with reduced file size (low quality).