<Composition>
The video: frame rate, size, background and theme. It ends where its content ends.
tsx
import { Clip, Composition, Title, Track } from "@cutcraft/kit";
export default function Video() {
return (
<Composition fps={30} width={960} height={540}>
<Track id="main">
<Clip id="shot" src="asset:aurora" in={0} out={4} fit="cover" />
</Track>
<Track id="text">
<Title id="title" anchor="shot" offset={0.4} duration={3.2} size={56}>
One file, one video
</Title>
</Track>
</Composition>
);
}Used in: Product launch · Kinetic type · Data story · Logo reveal · An edit · Captions and key points · the walkthrough · Brand spot in any theme · Multicam highlights · Product demo with zoom-ins · Slideshow with motion · Stats with handles · Talking-head cut · Variants from one file · Vertical clip from a podcast
Props
| prop | type | default | required | description |
|---|---|---|---|---|
id | string | "composition" | The video's name. | |
fps | number (>0..240) | yes | Frames per second. | |
width | integer (16..8192) | yes | The frame's width in pixels. | |
height | integer (16..8192) | yes | The frame's height in pixels. | |
sampleRate | integer (8000..192000) | 48000 | The soundtrack's samples per second. | |
channels | integer (1..8) | 2 | The soundtrack's channels: 1 is mono, 2 stereo. | |
background | What shows where nothing covers the frame: a colour, a gradient, or (blur) the picture itself, blurred to fill. | |||
theme | The video's look: palette, fonts, radius, motion style and element presets. Elements use it through $tokens and style. | |||
motionBlur | A film camera's blur on everything that moves, in the export: each frame averages samples moments across the time its shutter is open, shutterAngle degrees of the frame (180 is half the frame, the film default). Drawn by the browser export, which a file with it uses on its own; the preview stays sharp. |
Children: track, marker, multicam, captions. All elements