Video templates are in beta. The editor, the API, and the SDK methods can still change.
How a video template works
A video template is a template with a timeline. Each top-level layer has a start and an end on the timeline, and up to one animation of each kind:
Text reveal, Typewriter, and Count up are for text layers. Ken Burns is for images and video layers.
A video can also have music, and video layers that play a clip.
Design a video
- Click New template, then Blank video. The editor opens a 1080 by 1920 canvas with a 5-second timeline at 30 fps.
- Add layers as in an image template: text, images, shapes, and frames. To add a clip, use Objects → Video, or drop a video file on the canvas.
- Drag the bars on the timeline to set when each layer starts and ends.
- Select a layer and open the Motion tab of the right panel. Set its timing, then pick an Enter, Exit, Ambient, or Behavior preset. Start after makes a layer start when another layer ends.
- With no layer selected, the Motion tab sets the duration (up to 60 seconds), the frame rate (24, 25, 30, or 60 fps), and the music, with its start and volume.
- Press play to watch the video.
Render a video
Send aPOST request to /v1/templates/renderVideo with the template id and your modifications:
- A modification with the name of a video layer and a
srcchanges the clip of that layer. - The modification named
musicwith asrcchanges the music. The music keeps its start and volume.
Follow the progress
A render takes longer than an image, and a video can wait in line for a renderer. Add?stream=true to get server-sent events while it renders:
The SDKs read these events for you. See the JavaScript, PHP, Go, and Python guides.
Usage
Each second of video counts as one generation, rounded up. A 5-second video counts 5 generations, and a 7.5-second video counts 8. A render that fails counts nothing.Limits
The sound of a video layer is not in the MP4. Use the music for sound.