Creates a CanvasRecorder. Throws, if it is not supported on the used platform.
The canvas to record.
Returns a new blob of all recorded, available images.
Returns the recorded images. Note: Images are not necessarily immediately available after stopping.
Sets the onImagesAvailable callback.
Returns the state the CanvasRecorder currently is in.
Creates a temporary hyperlink element and triggers a download of the blob with the given file name. Both, the hyperlink element and the blob url are removed automatically shortly after the hyperlink click was triggered.
Explicitly records a single frame from the canvas. This can be used when start was called with fps = 0.
Pauses recording. Can be later resumed with resume. Must not be called while not already recording.
Resumes recording. Must not be called while not already recording.
Starts recording the the canvas. If the given fps is 0 it won't automatically record. Instead frame has to be called every time a new frame should get recorded. Must not be called with negative fps, while already recording or with an unsupported MIME type.
Maximum fps to record in.
The MIME video type.
Stops recording the canvas. Must not be called while not already recording.
Checks whether the given MIME type is supported.
MIME type to check.
Checks whether recording the canvas is supported.
Class to record the contents of a Canvas. Some time after stopping the CanvasRecorder the recorded images will be available as Array of Blobs. The images can be retrieved by setting the onImagesAvailable callback. Exemplary usage: