exportVideo
Render an edited OpenScreen project to MP4 (H.264) or GIF with the compositor, applying background, cursor, zooms, cuts, speed changes, and annotations. Returns the output file path.
Instructions
Render a project to an MP4 (H.264) or a GIF with OpenScreen's compositor: the background, cursor, zooms, cuts, speed changes and annotations as edited. Returns the file's path; call getFrames with the projectId to check it at the ruler seconds you edited with. The video's shape follows the project's format (setAspectRatio). The options are the Export dialog's: quality and fps for an MP4; gifFrameRate, gifSize and gifLoop for a GIF.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fps | No | MP4 only. Frames per second. Default 60. | |
| path | Yes | Where to write the video: an absolute path, or one relative to this server's working directory, ending in .mp4 or .gif. | |
| gifLoop | No | GIF only. Loop forever (default) or play once. | |
| gifSize | No | GIF only. The largest height in pixels, never upscaled: small 480, medium 720, large 1080, original keeps the recording's. Default medium. | |
| quality | No | MP4 only. The height: medium is 720 pixels, good is 1080 (default), source keeps the recording's. The width follows the format. | |
| projectId | Yes | ||
| gifFrameRate | No | GIF only. Frames per second. Default 15. |