Protected_Protected Optional_Protected_Where the frames of an image sequence go. Default: a folder the user picks (DirectoryFrameSink) in a browser that can (Chromium), and one zip download (ZipFrameSink) in the others (Safari, Firefox). A zip works in every browser, and holds the frames in memory until the end; a function or your own ICanvasFrameSink can send them to a server or memory. In converge mode the next frame waits for the sink. A failure is reported when the recording stops. Not saved with the plugin's settings.
A failed recording shows why in a toast (viewer.dialog.toast, where the viewer's dialog has toasts), like a
browser that can't save to a folder or a write that failed. Cancelling the folder picker shows none. The error
event and a rejected record report it in code either way.
Static Optional ReadonlyOldStatic ReadonlyPluginThe converge mode and the frame rate of the running recording, from its start until it stops. A change of convergeMode or videoFrameRate during a recording applies to the next one, so the frames, the animation steps (ProgressivePlugin.postFrameConvergedRecordingDelta) and the encoded frame rate match.
Protected_Protected_Protected_Optionalprefix: stringWhether the recorder can take a frame now. A browser recorder in converge mode records each frame for one frame time: until then, no frame is requested and the animations do not step (ProgressivePlugin.postFrameConvergedRecordingDelta), so each pose gets its own frame.
Prompts for duration if not specified
Optionalease: EasingOptionalonStart: () => voidOptionalmeta: SerializationMetaTypeOptionalonStart: () => voidAdds a recorder, for a new output with no change to this plugin. It's used when mimeType matches, and over the built-in ones. The last one registered for a format wins. Not while a recording runs.
unique; registering a name again replaces that recorder
makes the recorder from the viewer's canvas, once, when it's first needed
which values of mimeType it records. Default: the one equal to name
Optionalui: { label: string; mimeType: string }
an entry in the format list of the plugin's UI: its label and the mimeType it sets
false when a recording runs, and nothing changed
OptionalsetStops the recording and resolves with the recording (no blob for an image sequence). A second call while the recording stops gets the same promise.
Optionalmeta: SerializationMetaTypeRemoves a recorder added with registerRecorder. Not while a recording runs.
false when a recording runs, or nothing has that name
Waits for a time of the video: in a converge-mode recording, for the steps of the recording (one frame each, as
the animations step), so a pause has its length in the video; else for the wall time. A scene that does not
converge (no step in maxFrameCount frames, e.g. a plugin that stays dirty) waits the rest on the wall clock.
The frames in which a browser recorder still records a frame (canRecordFrame) do not count as such for
two frame times of the video. It ends early when the recording ends.
the time in milliseconds
Canvas Recorder Plugin
Records the viewer canvas to a video (MP4 with ffmpeg.js, or the browser's MediaRecorder) or to an image sequence. In converge mode, each video frame is captured only after the ProgressivePlugin has converged, and the animations step by
1 / videoFrameRateper captured frame (see ProgressivePlugin.postFrameConvergedRecordingDelta).The MP4 recorder loads ffmpeg.js from FFMPEGRecorder.LIBRARY_PATH when it is created.