Skip to content

🎥 Make videos programmatically with React

refactor offthreadVideoCacheSizeInBytes

Jonny Burger608e2361cd4a
diff --git a/packages/cli/src/benchmark.ts b/packages/cli/src/benchmark.ts
index 62e153fb55..53135ffd1d 100644
--- a/packages/cli/src/benchmark.ts
+++ b/packages/cli/src/benchmark.ts
@@ -187,7 +187,6 @@ export const benchmarkCommand = async (
height,
width,
concurrency: unparsedConcurrency,
- offthreadVideoCacheSizeInBytes,
colorSpace,
} = getCliOptions({
isLambda: false,
@@ -261,7 +260,10 @@ export const benchmarkCommand = async (
// Intentionally disabling server to not cache results
server: undefined,
logLevel,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes:
+ BrowserSafeApis.options.offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: parsedCli,
+ }).value,
});
const ids = (
@@ -382,7 +384,12 @@ export const benchmarkCommand = async (
indent: undefined,
staticBase: null,
}).serializedString,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes:
+ BrowserSafeApis.options.offthreadVideoCacheSizeInBytesOption.getValue(
+ {
+ commandLine: parsedCli,
+ },
+ ).value,
colorSpace,
repro: false,
finishRenderProgress: () => undefined,
diff --git a/packages/cli/src/compositions.ts b/packages/cli/src/compositions.ts
index 7206ab30b5..824241d949 100644
--- a/packages/cli/src/compositions.ts
+++ b/packages/cli/src/compositions.ts
@@ -1,12 +1,13 @@
import type {LogLevel} from '@remotion/renderer';
import {RenderInternals} from '@remotion/renderer';
+import {BrowserSafeApis} from '@remotion/renderer/client';
import {NoReactInternals} from 'remotion/no-react';
import {registerCleanupJob} from './cleanup-before-quit';
import {getRendererPortFromConfigFileAndCliFlag} from './config/preview-server';
import {findEntryPoint} from './entry-point';
import {getCliOptions} from './get-cli-options';
import {Log} from './log';
-import {quietFlagProvided} from './parse-command-line';
+import {parsedCli, quietFlagProvided} from './parse-command-line';
import {printCompositions} from './print-compositions';
import {bundleOnCliOrTakeServeUrl} from './setup-cache';
@@ -43,7 +44,6 @@ export const listCompositionsCommand = async (
inputProps,
puppeteerTimeout,
publicDir,
- offthreadVideoCacheSizeInBytes,
} = getCliOptions({
isLambda: false,
type: 'get-compositions',
@@ -93,7 +93,10 @@ export const listCompositionsCommand = async (
puppeteerInstance: undefined,
logLevel,
server: undefined,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes:
+ BrowserSafeApis.options.offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: parsedCli,
+ }).value,
});
printCompositions(compositions);
diff --git a/packages/cli/src/config/index.ts b/packages/cli/src/config/index.ts
index 886d8194e0..3d6c0aae20 100644
--- a/packages/cli/src/config/index.ts
+++ b/packages/cli/src/config/index.ts
@@ -106,10 +106,6 @@ import {getMuted, setMuted} from './muted';
import type {Loop} from './number-of-gif-loops';
import {getNumberOfGifLoops, setNumberOfGifLoops} from './number-of-gif-loops';
import {setNumberOfSharedAudioTags} from './number-of-shared-audio-tags';
-import {
- getOffthreadVideoCacheSizeInBytes,
- setOffthreadVideoCacheSizeInBytes,
-} from './offthread-video-cache-size';
import {getShouldOpenBrowser, setShouldOpenBrowser} from './open-browser';
import {setOutputLocation} from './output-location';
import type {WebpackOverrideFn} from './override-webpack';
@@ -132,6 +128,9 @@ import {getWidth, overrideWidth} from './width';
export type {Concurrency, WebpackConfiguration, WebpackOverrideFn};
+const {offthreadVideoCacheSizeInBytesOption, x264Option, audioBitrateOption} =
+ BrowserSafeApis.options;
+
declare global {
interface RemotionBundlingOptions {
/**
@@ -602,17 +601,19 @@ export const Config: FlatConfig = {
setImageSequence,
setProResProfile,
setX264Preset: (preset) => {
- BrowserSafeApis.options.x264Option.setConfig(preset);
+ x264Option.setConfig(preset ?? null);
},
setAudioBitrate: (bitrate) => {
- BrowserSafeApis.options.audioBitrateOption.setConfig(bitrate);
+ audioBitrateOption.setConfig(bitrate);
},
setVideoBitrate,
overrideHeight,
overrideWidth,
overrideFfmpegCommand: setFfmpegOverrideFunction,
setAudioCodec,
- setOffthreadVideoCacheSizeInBytes,
+ setOffthreadVideoCacheSizeInBytes: (size) => {
+ offthreadVideoCacheSizeInBytesOption.setConfig(size);
+ },
setDeleteAfter,
setColorSpace,
setBeepOnFinish,
@@ -674,7 +675,6 @@ export const ConfigInternals = {
getWebpackPolling,
getShouldOpenBrowser,
getChromiumUserAgent,
- getOffthreadVideoCacheSizeInBytes,
getDeleteAfter,
getColorSpace,
getEnableFolderExpiry,
diff --git a/packages/cli/src/config/offthread-video-cache-size.ts b/packages/cli/src/config/offthread-video-cache-size.ts
deleted file mode 100644
index 0b13f4ce2f..0000000000
--- a/packages/cli/src/config/offthread-video-cache-size.ts
+++ /dev/null
@@ -1,9 +0,0 @@
-let offthreadVideoCacheSizeInBytes: number | null = null;
-
-export const getOffthreadVideoCacheSizeInBytes = () => {
- return offthreadVideoCacheSizeInBytes;
-};
-
-export const setOffthreadVideoCacheSizeInBytes = (size: number | null) => {
- offthreadVideoCacheSizeInBytes = size;
-};
diff --git a/packages/cli/src/get-cli-options.ts b/packages/cli/src/get-cli-options.ts
index 02503f7542..1a462ccf25 100644
--- a/packages/cli/src/get-cli-options.ts
+++ b/packages/cli/src/get-cli-options.ts
@@ -150,8 +150,6 @@ export const getCliOptions = (options: {
height,
width,
configFileImageFormat: ConfigInternals.getUserPreferredVideoImageFormat(),
- offthreadVideoCacheSizeInBytes:
- ConfigInternals.getOffthreadVideoCacheSizeInBytes(),
deleteAfter: ConfigInternals.getDeleteAfter(),
colorSpace: ConfigInternals.getColorSpace(),
repro: ConfigInternals.getRepro(),
diff --git a/packages/cli/src/get-render-defaults.ts b/packages/cli/src/get-render-defaults.ts
index 0135c0fb6d..e2ac4ef299 100644
--- a/packages/cli/src/get-render-defaults.ts
+++ b/packages/cli/src/get-render-defaults.ts
@@ -4,7 +4,8 @@ import type {RenderDefaults} from '@remotion/studio';
import {ConfigInternals} from './config';
import {parsedCli} from './parse-command-line';
-const {x264Option, audioBitrateOption} = BrowserSafeApis.options;
+const {x264Option, audioBitrateOption, offthreadVideoCacheSizeInBytesOption} =
+ BrowserSafeApis.options;
export const getRenderDefaults = (): RenderDefaults => {
const defaultJpegQuality = ConfigInternals.getJpegQuality();
@@ -25,6 +26,10 @@ export const getRenderDefaults = (): RenderDefaults => {
const audioBitrate = audioBitrateOption.getValue({
commandLine: parsedCli,
}).value;
+ const offthreadVideoCacheSizeInBytes =
+ offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: parsedCli,
+ }).value;
const videoBitrate = ConfigInternals.getVideoBitrate();
const encodingBufferSize = ConfigInternals.getEncodingBufferSize();
const encodingMaxRate = ConfigInternals.getEncodingMaxRate();
@@ -39,8 +44,6 @@ export const getRenderDefaults = (): RenderDefaults => {
const headless = ConfigInternals.getChromiumHeadlessMode();
const ignoreCertificateErrors = ConfigInternals.getIgnoreCertificateErrors();
const openGlRenderer = ConfigInternals.getChromiumOpenGlRenderer();
- const offthreadVideoCacheSizeInBytes =
- ConfigInternals.getOffthreadVideoCacheSizeInBytes();
const colorSpace = ConfigInternals.getColorSpace();
const userAgent = ConfigInternals.getChromiumUserAgent();
diff --git a/packages/cli/src/parse-command-line.ts b/packages/cli/src/parse-command-line.ts
index 07e3176229..27e0ab9804 100644
--- a/packages/cli/src/parse-command-line.ts
+++ b/packages/cli/src/parse-command-line.ts
@@ -19,7 +19,7 @@ import {Log} from './log';
const {
beepOnFinishOption,
colorSpaceOption,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytesOption,
encodingBufferSizeOption,
encodingMaxRateOption,
deleteAfterOption,
@@ -42,8 +42,8 @@ type CommandLineOptions = {
['every-nth-frame']: number;
[numberOfGifLoopsOption.cliFlag]: number;
['number-of-shared-audio-tags']: number;
- [offthreadVideoCacheSizeInBytes.cliFlag]: TypeOfOption<
- typeof offthreadVideoCacheSizeInBytes
+ [offthreadVideoCacheSizeInBytesOption.cliFlag]: TypeOfOption<
+ typeof offthreadVideoCacheSizeInBytesOption
>;
[colorSpaceOption.cliFlag]: TypeOfOption<typeof colorSpaceOption>;
[beepOnFinishOption.cliFlag]: TypeOfOption<typeof beepOnFinishOption>;
diff --git a/packages/cli/src/render-flows/render.ts b/packages/cli/src/render-flows/render.ts
index 90d7accf6a..3dbb2be3ed 100644
--- a/packages/cli/src/render-flows/render.ts
+++ b/packages/cli/src/render-flows/render.ts
@@ -141,7 +141,7 @@ export const renderVideoFlow = async ({
muted: boolean;
enforceAudioTrack: boolean;
proResProfile: ProResProfile | undefined;
- x264Preset: X264Preset | undefined;
+ x264Preset: X264Preset | null;
pixelFormat: PixelFormat;
numberOfGifLoops: Loop;
audioCodec: AudioCodec | null;
diff --git a/packages/cli/src/render-queue/process-video.ts b/packages/cli/src/render-queue/process-video.ts
index e75b52b587..fc6cd4ecd9 100644
--- a/packages/cli/src/render-queue/process-video.ts
+++ b/packages/cli/src/render-queue/process-video.ts
@@ -71,7 +71,7 @@ export const processVideoJob = async ({
enforceAudioTrack: job.type === 'video' ? job.enforceAudioTrack : false,
proResProfile:
job.type === 'video' ? job.proResProfile ?? undefined : undefined,
- x264Preset: job.type === 'video' ? job.x264Preset ?? undefined : undefined,
+ x264Preset: job.type === 'video' ? job.x264Preset ?? null : null,
pixelFormat: job.type === 'video' ? job.pixelFormat : 'yuv420p',
videoBitrate: job.type === 'video' ? job.videoBitrate : null,
encodingBufferSize: job.type === 'video' ? job.encodingBufferSize : null,
diff --git a/packages/cli/src/render.tsx b/packages/cli/src/render.tsx
index cae7259a86..baebc8c13f 100644
--- a/packages/cli/src/render.tsx
+++ b/packages/cli/src/render.tsx
@@ -13,7 +13,8 @@ import {Log} from './log';
import {parsedCli, quietFlagProvided} from './parse-command-line';
import {renderVideoFlow} from './render-flows/render';
-const {x264Option, audioBitrateOption} = BrowserSafeApis.options;
+const {x264Option, audioBitrateOption, offthreadVideoCacheSizeInBytesOption} =
+ BrowserSafeApis.options;
export const render = async (
remotionRoot: string,
@@ -70,7 +71,6 @@ export const render = async (
encodingMaxRate,
encodingBufferSize,
numberOfGifLoops,
- offthreadVideoCacheSizeInBytes,
colorSpace,
repro,
} = getCliOptions({
@@ -84,6 +84,10 @@ export const render = async (
const {value: audioBitrate} = audioBitrateOption.getValue({
commandLine: parsedCli,
});
+ const {value: offthreadVideoCacheSizeInBytes} =
+ offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: parsedCli,
+ });
const audioCodec = getResolvedAudioCodec();
diff --git a/packages/cli/src/still.ts b/packages/cli/src/still.ts
index c11267d4df..83ac5b9c05 100644
--- a/packages/cli/src/still.ts
+++ b/packages/cli/src/still.ts
@@ -1,4 +1,5 @@
import type {LogLevel} from '@remotion/renderer';
+import {BrowserSafeApis} from '@remotion/renderer/client';
import {NoReactInternals} from 'remotion/no-react';
import {registerCleanupJob} from './cleanup-before-quit';
import {getRendererPortFromConfigFileAndCliFlag} from './config/preview-server';
@@ -9,6 +10,8 @@ import {Log} from './log';
import {parsedCli} from './parse-command-line';
import {renderStillFlow} from './render-flows/still';
+const {offthreadVideoCacheSizeInBytesOption} = BrowserSafeApis.options;
+
export const still = async (
remotionRoot: string,
args: string[],
@@ -51,7 +54,6 @@ export const still = async (
scale,
stillFrame,
width,
- offthreadVideoCacheSizeInBytes,
} = getCliOptions({
isLambda: false,
type: 'still',
@@ -93,6 +95,9 @@ export const still = async (
},
cancelSignal: null,
outputLocationFromUi: null,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes:
+ offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: parsedCli,
+ }).value,
});
};
diff --git a/packages/cloudrun/src/cli/commands/render/index.ts b/packages/cloudrun/src/cli/commands/render/index.ts
index f2c59e1bde..1ec82e1103 100644
--- a/packages/cloudrun/src/cli/commands/render/index.ts
+++ b/packages/cloudrun/src/cli/commands/render/index.ts
@@ -15,7 +15,8 @@ import {renderArgsCheck} from './helpers/renderArgsCheck';
export const RENDER_COMMAND = 'render';
-const {audioBitrateOption, x264Option} = BrowserSafeApis.options;
+const {audioBitrateOption, x264Option, offthreadVideoCacheSizeInBytesOption} =
+ BrowserSafeApis.options;
export const renderCommand = async (
args: string[],
@@ -66,7 +67,6 @@ export const renderCommand = async (
width,
browserExecutable,
enforceAudioTrack,
- offthreadVideoCacheSizeInBytes,
colorSpace,
} = CliInternals.getCliOptions({
type: 'series',
@@ -75,6 +75,10 @@ export const renderCommand = async (
logLevel,
});
+ const offthreadVideoCacheSizeInBytes =
+ offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: CliInternals.parsedCli,
+ }).value;
let composition: string = args[1];
if (!composition) {
Log.info('No compositions passed. Fetching compositions...');
@@ -94,7 +98,7 @@ export const renderCommand = async (
remotionRoot,
logLevel,
webpackConfigOrServeUrl: serveUrl,
- offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytes ?? null,
+ offthreadVideoCacheSizeInBytes,
});
const {compositionId} =
@@ -189,7 +193,6 @@ ${downloadName ? ` Downloaded File = ${downloadName}` : ''}
const audioBitrate = audioBitrateOption.getValue({
commandLine: CliInternals.parsedCli,
}).value;
-
const res = await internalRenderMediaOnCloudrun({
cloudRunUrl,
serviceName: undefined,
diff --git a/packages/cloudrun/src/cli/commands/still.ts b/packages/cloudrun/src/cli/commands/still.ts
index 334ef5ddbf..0f183f8b89 100644
--- a/packages/cloudrun/src/cli/commands/still.ts
+++ b/packages/cloudrun/src/cli/commands/still.ts
@@ -2,6 +2,7 @@ import {CliInternals} from '@remotion/cli';
import {ConfigInternals} from '@remotion/cli/config';
import type {LogLevel} from '@remotion/renderer';
import {RenderInternals} from '@remotion/renderer';
+import {BrowserSafeApis} from '@remotion/renderer/client';
import {NoReactInternals} from 'remotion/no-react';
import {downloadFile} from '../../api/download-file';
import {renderStillOnCloudrun} from '../../api/render-still-on-cloudrun';
@@ -38,7 +39,6 @@ export const stillCommand = async (
height,
width,
browserExecutable,
- offthreadVideoCacheSizeInBytes,
} = CliInternals.getCliOptions({
type: 'still',
isLambda: true,
@@ -58,6 +58,11 @@ export const stillCommand = async (
);
}
+ const offthreadVideoCacheSizeInBytes =
+ BrowserSafeApis.options.offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: CliInternals.parsedCli,
+ }).value;
+
const server = RenderInternals.prepareServer({
concurrency: 1,
indent: false,
diff --git a/packages/lambda/src/cli/commands/render/render.ts b/packages/lambda/src/cli/commands/render/render.ts
index 02ad5d0d05..eff18129e4 100644
--- a/packages/lambda/src/cli/commands/render/render.ts
+++ b/packages/lambda/src/cli/commands/render/render.ts
@@ -40,7 +40,8 @@ function getTotalFrames(status: RenderProgress): number | null {
: null;
}
-const {x264Option, audioBitrateOption} = BrowserSafeApis.options;
+const {x264Option, audioBitrateOption, offthreadVideoCacheSizeInBytesOption} =
+ BrowserSafeApis.options;
export const renderCommand = async (
args: string[],
@@ -83,7 +84,6 @@ export const renderCommand = async (
height,
width,
browserExecutable,
- offthreadVideoCacheSizeInBytes,
colorSpace,
deleteAfter,
} = CliInternals.getCliOptions({
@@ -99,6 +99,10 @@ export const renderCommand = async (
const audioBitrate = audioBitrateOption.getValue({
commandLine: CliInternals.parsedCli,
}).value;
+ const offthreadVideoCacheSizeInBytes =
+ offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: CliInternals.parsedCli,
+ }).value;
let composition: string = args[1];
if (!composition) {
diff --git a/packages/lambda/src/cli/commands/still.ts b/packages/lambda/src/cli/commands/still.ts
index ad59e56414..7a7ae8193f 100644
--- a/packages/lambda/src/cli/commands/still.ts
+++ b/packages/lambda/src/cli/commands/still.ts
@@ -52,7 +52,6 @@ export const stillCommand = async (
height,
width,
browserExecutable,
- offthreadVideoCacheSizeInBytes,
} = CliInternals.getCliOptions({
type: 'still',
isLambda: true,
@@ -73,6 +72,11 @@ export const stillCommand = async (
);
}
+ const offthreadVideoCacheSizeInBytes =
+ BrowserSafeApis.options.offthreadVideoCacheSizeInBytesOption.getValue({
+ commandLine: CliInternals.parsedCli,
+ }).value;
+
const server = await RenderInternals.prepareServer({
concurrency: 1,
indent: false,
diff --git a/packages/renderer/src/options/index.tsx b/packages/renderer/src/options/index.tsx
index 7a50e50be7..11984e17e2 100644
--- a/packages/renderer/src/options/index.tsx
+++ b/packages/renderer/src/options/index.tsx
@@ -13,7 +13,7 @@ import {glOption} from './gl';
import {jpegQualityOption} from './jpeg-quality';
import {muteOption} from './mute';
import {numberOfGifLoopsOption} from './number-of-gif-loops';
-import {offthreadVideoCacheSizeInBytes} from './offthreadvideo-cache-size';
+import {offthreadVideoCacheSizeInBytesOption} from './offthreadvideo-cache-size';
import type {AnyRemotionOption} from './option';
import {reproOption} from './repro';
import {scaleOption} from './scale';
@@ -31,7 +31,7 @@ export const allOptions = {
enforceAudioOption,
muteOption,
videoCodecOption,
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytesOption,
webhookCustomDataOption,
colorSpaceOption,
deleteAfterOption,
diff --git a/packages/renderer/src/options/offthreadvideo-cache-size.tsx b/packages/renderer/src/options/offthreadvideo-cache-size.tsx
index f3b11b30a4..0e9e4a11a1 100644
--- a/packages/renderer/src/options/offthreadvideo-cache-size.tsx
+++ b/packages/renderer/src/options/offthreadvideo-cache-size.tsx
@@ -1,8 +1,16 @@
import type {AnyRemotionOption} from './option';
-export const offthreadVideoCacheSizeInBytes = {
+let offthreadVideoCacheSizeInBytes: number | null = null;
+
+export const getOffthreadVideoCacheSizeInBytes = () => {
+ return offthreadVideoCacheSizeInBytes;
+};
+
+const cliFlag = 'offthreadvideo-cache-size-in-bytes' as const;
+
+export const offthreadVideoCacheSizeInBytesOption = {
name: 'OffthreadVideo cache size',
- cliFlag: 'offthreadvideo-cache-size-in-bytes' as const,
+ cliFlag,
description: () => (
<>
From v4.0, Remotion has a cache for{' '}
@@ -22,6 +30,29 @@ export const offthreadVideoCacheSizeInBytes = {
ssrName: 'offthreadVideoCacheSizeInBytes' as const,
docLink: 'https://www.remotion.dev/docs/offthreadvideo',
type: 0 as number | null,
+ getValue: ({commandLine}) => {
+ if (commandLine[cliFlag] !== undefined) {
+ return {
+ source: 'cli',
+ value: commandLine[cliFlag] as number,
+ };
+ }
+
+ if (offthreadVideoCacheSizeInBytes !== null) {
+ return {
+ source: 'config',
+ value: offthreadVideoCacheSizeInBytes,
+ };
+ }
+
+ return {
+ source: 'default',
+ value: null,
+ };
+ },
+ setConfig: (size: number | null) => {
+ offthreadVideoCacheSizeInBytes = size ?? null;
+ },
} satisfies AnyRemotionOption<number | null>;
export const validateOffthreadVideoCacheSizeInBytes = (option: unknown) => {
diff --git a/packages/renderer/src/options/options-map.ts b/packages/renderer/src/options/options-map.ts
index 60b2d73ca7..277e62e413 100644
--- a/packages/renderer/src/options/options-map.ts
+++ b/packages/renderer/src/options/options-map.ts
@@ -6,7 +6,7 @@ import {encodingMaxRateOption} from './encoding-max-rate';
import {jpegQualityOption} from './jpeg-quality';
import {muteOption} from './mute';
import {numberOfGifLoopsOption} from './number-of-gif-loops';
-import {offthreadVideoCacheSizeInBytes} from './offthreadvideo-cache-size';
+import {offthreadVideoCacheSizeInBytesOption} from './offthreadvideo-cache-size';
import {reproOption} from './repro';
import {videoBitrate} from './video-bitrate';
import {videoCodecOption} from './video-codec';
@@ -14,7 +14,7 @@ import {x264Option} from './x264-preset';
export const optionsMap = {
renderMedia: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
videoBitrate,
numberOfGifLoops: numberOfGifLoopsOption,
repro: reproOption,
@@ -28,21 +28,21 @@ export const optionsMap = {
muted: muteOption,
},
renderStill: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
jpegQuality: jpegQualityOption,
},
getCompositions: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
},
selectComposition: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
},
renderFrames: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
jpegQuality: jpegQualityOption,
},
renderMediaOnLambda: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
videoBitrate,
numberOfGifLoops: numberOfGifLoopsOption,
audioBitrate: audioBitrateOption,
@@ -54,14 +54,14 @@ export const optionsMap = {
muted: muteOption,
},
renderStillOnLambda: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
jpegQuality: jpegQualityOption,
},
getCompositionsOnLambda: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
},
renderMediaOnCloudRun: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
numberOfGifLoops: numberOfGifLoopsOption,
colorSpace: colorSpaceOption,
audioBitrate: audioBitrateOption,
@@ -72,6 +72,6 @@ export const optionsMap = {
muted: muteOption,
},
renderStillOnCloudRun: {
- offthreadVideoCacheSizeInBytes,
+ offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytesOption,
},
} as const;
diff --git a/packages/studio/src/components/RenderModal/RenderModalAdvanced.tsx b/packages/studio/src/components/RenderModal/RenderModalAdvanced.tsx
index 91c66b1b28..f4cf33e89b 100644
--- a/packages/studio/src/components/RenderModal/RenderModalAdvanced.tsx
+++ b/packages/studio/src/components/RenderModal/RenderModalAdvanced.tsx
@@ -310,7 +310,7 @@ export const RenderModalAdvanced: React.FC<{
<div style={optionRow}>
<div style={label}>Custom OffthreadVideo cache</div>
<Spacing x={0.5} />
- <OptionExplainerBubble id="offthreadVideoCacheSizeInBytes" />
+ <OptionExplainerBubble id="offthreadVideoCacheSizeInBytesOption" />
<div style={rightRow}>
<Checkbox
checked={offthreadVideoCacheSizeInBytes !== null}