Skip to content

🎥 Make videos programmatically with React

Merge branch 'main' into render-series

Jonny Burger99bcab2ae61d
diff --cc packages/cli/src/preview-server/render-queue/process-video.ts
index 783f3b6181,ea7a9e78f3..385a689302
--- a/packages/cli/src/preview-server/render-queue/process-video.ts
+++ b/packages/cli/src/preview-server/render-queue/process-video.ts
@@@ -51,29 -52,28 +51,30 @@@ export const processVideoJob = async (
onProgress,
indent: true,
concurrency: job.concurrency,
- everyNthFrame: job.everyNthFrame,
+ everyNthFrame: job.type === 'video' ? job.everyNthFrame : 1,
frameRange: [job.startFrame, job.endFrame],
quiet: false,
- shouldOutputImageSequence: false,
+ shouldOutputImageSequence: job.type === 'sequence',
addCleanupCallback,
outputLocationFromUI: job.outName,
- uiCodec: job.codec,
+ uiCodec: job.type === 'video' ? job.codec : null,
uiImageFormat: job.imageFormat,
cancelSignal: job.cancelToken.cancelSignal,
- crf: job.crf,
+ crf: job.type === 'video' ? job.crf : null,
ffmpegOverride,
- audioBitrate: job.audioBitrate,
- muted: job.muted,
- enforceAudioTrack: job.enforceAudioTrack,
- proResProfile: job.proResProfile ?? undefined,
- x264Preset: job.x264Preset ?? undefined,
- pixelFormat: job.pixelFormat,
- videoBitrate: job.videoBitrate,
- numberOfGifLoops: job.numberOfGifLoops,
- audioCodec: job.audioCodec,
- disallowParallelEncoding: job.disallowParallelEncoding,
+ audioBitrate: job.type === 'video' ? job.audioBitrate : null,
+ muted: job.type === 'video' ? job.muted : true,
+ enforceAudioTrack: job.type === 'video' ? job.enforceAudioTrack : false,
+ proResProfile:
+ job.type === 'video' ? job.proResProfile ?? undefined : undefined,
+ x264Preset: job.type === 'video' ? job.x264Preset ?? undefined : undefined,
+ pixelFormat: job.type === 'video' ? job.pixelFormat : 'yuv420p',
+ videoBitrate: job.type === 'video' ? job.videoBitrate : null,
+ numberOfGifLoops: job.type === 'video' ? job.numberOfGifLoops : null,
+ audioCodec: job.type === 'video' ? job.audioCodec : null,
+ disallowParallelEncoding:
+ job.type === 'video' ? job.disallowParallelEncoding : false,
offthreadVideoCacheSizeInBytes: job.offthreadVideoCacheSizeInBytes,
+ colorSpace: job.colorSpace,
});
};
diff --cc packages/cli/src/render-flows/render.ts
index 7e25ede33b,ee84a78aaa..bb2477dd84
--- a/packages/cli/src/render-flows/render.ts
+++ b/packages/cli/src/render-flows/render.ts
@@@ -139,8 -141,10 +141,9 @@@ export const renderVideoFlow = async (
audioCodec: AudioCodec | null;
disallowParallelEncoding: boolean;
offthreadVideoCacheSizeInBytes: number | null;
+ colorSpace: ColorSpace;
}) => {
const downloads: DownloadProgress[] = [];
-
if (browserExecutable) {
Log.verboseAdvanced(
{indent, logLevel},