@remotion/renderer 4.0.118 → 4.0.120
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/get-audio-channels.d.ts +8 -2
- package/dist/assets/get-audio-channels.js +18 -6
- package/dist/call-ffmpeg.d.ts +4 -3
- package/dist/call-ffmpeg.js +14 -4
- package/dist/client.d.ts +154 -64
- package/dist/combine-videos.d.ts +1 -0
- package/dist/combine-videos.js +2 -1
- package/dist/compositor/compose.d.ts +1 -1
- package/dist/compositor/compose.js +7 -2
- package/dist/compositor/compositor.d.ts +9 -2
- package/dist/compositor/compositor.js +19 -8
- package/dist/compositor/get-executable-path.d.ts +6 -1
- package/dist/compositor/get-executable-path.js +2 -2
- package/dist/copy-to-clipboard.d.ts +1 -1
- package/dist/copy-to-clipboard.js +2 -1
- package/dist/create-ffmpeg-complex-filter.d.ts +4 -1
- package/dist/create-silent-audio.d.ts +2 -1
- package/dist/create-silent-audio.js +2 -1
- package/dist/extract-audio.d.ts +1 -0
- package/dist/extract-audio.js +2 -1
- package/dist/get-compositions.js +5 -2
- package/dist/get-extension-from-codec.d.ts +2 -2
- package/dist/get-silent-parts.d.ts +2 -1
- package/dist/get-silent-parts.js +2 -1
- package/dist/get-video-metadata.d.ts +1 -0
- package/dist/get-video-metadata.js +2 -1
- package/dist/guess-extension-for-media.d.ts +2 -1
- package/dist/guess-extension-for-media.js +2 -1
- package/dist/index.d.ts +90 -37
- package/dist/merge-audio-track.d.ts +1 -0
- package/dist/merge-audio-track.js +11 -2
- package/dist/offthread-video-server.d.ts +2 -1
- package/dist/offthread-video-server.js +12 -6
- package/dist/options/binaries-directory.d.ts +15 -0
- package/dist/options/binaries-directory.js +35 -0
- package/dist/options/color-space.d.ts +3 -3
- package/dist/options/gl.d.ts +3 -3
- package/dist/options/index.d.ts +27 -12
- package/dist/options/index.js +2 -0
- package/dist/options/option.d.ts +1 -1
- package/dist/options/options-map.d.ts +89 -14
- package/dist/options/options-map.js +6 -0
- package/dist/options/video-codec.d.ts +1 -1
- package/dist/pixel-format.d.ts +1 -1
- package/dist/prepare-server.d.ts +2 -1
- package/dist/prepare-server.js +3 -1
- package/dist/preprocess-audio-track.d.ts +1 -0
- package/dist/preprocess-audio-track.js +9 -3
- package/dist/prespawn-ffmpeg.d.ts +1 -0
- package/dist/prespawn-ffmpeg.js +1 -0
- package/dist/pure.d.ts +3 -3
- package/dist/render-frames.js +5 -2
- package/dist/render-media.d.ts +3 -1
- package/dist/render-media.js +7 -2
- package/dist/render-still.js +3 -1
- package/dist/select-composition.d.ts +1 -1
- package/dist/select-composition.js +5 -2
- package/dist/serve-static.d.ts +1 -0
- package/dist/serve-static.js +1 -0
- package/dist/stitch-frames-to-video.d.ts +3 -1
- package/dist/stitch-frames-to-video.js +9 -3
- package/dist/take-frame-and-compose.d.ts +0 -1
- package/dist/validate-output-filename.d.ts +1 -1
- package/package.json +9 -9
|
@@ -14,13 +14,14 @@ const delete_directory_1 = require("./delete-directory");
|
|
|
14
14
|
const p_limit_1 = require("./p-limit");
|
|
15
15
|
const tmp_dir_1 = require("./tmp-dir");
|
|
16
16
|
const truthy_1 = require("./truthy");
|
|
17
|
-
const mergeAudioTrackUnlimited = async ({ outName, files, numberOfSeconds, downloadMap, remotionRoot, indent, logLevel, }) => {
|
|
17
|
+
const mergeAudioTrackUnlimited = async ({ outName, files, numberOfSeconds, downloadMap, remotionRoot, indent, logLevel, binariesDirectory, }) => {
|
|
18
18
|
if (files.length === 0) {
|
|
19
19
|
await (0, create_silent_audio_1.createSilentAudio)({
|
|
20
20
|
outName,
|
|
21
21
|
numberOfSeconds,
|
|
22
22
|
indent,
|
|
23
23
|
logLevel,
|
|
24
|
+
binariesDirectory,
|
|
24
25
|
});
|
|
25
26
|
return;
|
|
26
27
|
}
|
|
@@ -40,6 +41,7 @@ const mergeAudioTrackUnlimited = async ({ outName, files, numberOfSeconds, downl
|
|
|
40
41
|
remotionRoot,
|
|
41
42
|
indent,
|
|
42
43
|
logLevel,
|
|
44
|
+
binariesDirectory,
|
|
43
45
|
});
|
|
44
46
|
return chunkOutname;
|
|
45
47
|
}));
|
|
@@ -57,6 +59,7 @@ const mergeAudioTrackUnlimited = async ({ outName, files, numberOfSeconds, downl
|
|
|
57
59
|
remotionRoot,
|
|
58
60
|
indent,
|
|
59
61
|
logLevel,
|
|
62
|
+
binariesDirectory,
|
|
60
63
|
});
|
|
61
64
|
return;
|
|
62
65
|
}
|
|
@@ -77,7 +80,13 @@ const mergeAudioTrackUnlimited = async ({ outName, files, numberOfSeconds, downl
|
|
|
77
80
|
]
|
|
78
81
|
.filter(truthy_1.truthy)
|
|
79
82
|
.flat(2);
|
|
80
|
-
const task = (0, call_ffmpeg_1.callFf)({
|
|
83
|
+
const task = (0, call_ffmpeg_1.callFf)({
|
|
84
|
+
bin: 'ffmpeg',
|
|
85
|
+
args,
|
|
86
|
+
indent,
|
|
87
|
+
logLevel,
|
|
88
|
+
binariesDirectory,
|
|
89
|
+
});
|
|
81
90
|
await task;
|
|
82
91
|
cleanup();
|
|
83
92
|
};
|
|
@@ -8,12 +8,13 @@ export declare const extractUrlAndSourceFromUrl: (url: string) => {
|
|
|
8
8
|
transparent: boolean;
|
|
9
9
|
toneMapped: boolean;
|
|
10
10
|
};
|
|
11
|
-
export declare const startOffthreadVideoServer: ({ downloadMap, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, }: {
|
|
11
|
+
export declare const startOffthreadVideoServer: ({ downloadMap, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, binariesDirectory, }: {
|
|
12
12
|
downloadMap: DownloadMap;
|
|
13
13
|
offthreadVideoCacheSizeInBytes: number | null;
|
|
14
14
|
concurrency: number;
|
|
15
15
|
logLevel: LogLevel;
|
|
16
16
|
indent: boolean;
|
|
17
|
+
binariesDirectory: string | null;
|
|
17
18
|
}) => {
|
|
18
19
|
listener: RequestListener;
|
|
19
20
|
close: () => Promise<void>;
|
|
@@ -36,13 +36,19 @@ const extractUrlAndSourceFromUrl = (url) => {
|
|
|
36
36
|
};
|
|
37
37
|
exports.extractUrlAndSourceFromUrl = extractUrlAndSourceFromUrl;
|
|
38
38
|
const REQUEST_CLOSED_TOKEN = 'Request closed';
|
|
39
|
-
const startOffthreadVideoServer = ({ downloadMap, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, }) => {
|
|
39
|
+
const startOffthreadVideoServer = ({ downloadMap, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, binariesDirectory, }) => {
|
|
40
40
|
(0, offthreadvideo_cache_size_1.validateOffthreadVideoCacheSizeInBytes)(offthreadVideoCacheSizeInBytes);
|
|
41
|
-
const compositor = (0, compositor_1.startCompositor)(
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
41
|
+
const compositor = (0, compositor_1.startCompositor)({
|
|
42
|
+
type: 'StartLongRunningProcess',
|
|
43
|
+
payload: {
|
|
44
|
+
concurrency,
|
|
45
|
+
maximum_frame_cache_size_in_bytes: offthreadVideoCacheSizeInBytes,
|
|
46
|
+
verbose: (0, log_level_1.isEqualOrBelowLogLevel)(logLevel, 'verbose'),
|
|
47
|
+
},
|
|
48
|
+
logLevel,
|
|
49
|
+
indent,
|
|
50
|
+
binariesDirectory,
|
|
51
|
+
});
|
|
46
52
|
return {
|
|
47
53
|
close: async () => {
|
|
48
54
|
// Note: This is being used as a promise:
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const binariesDirectoryOption: {
|
|
2
|
+
name: string;
|
|
3
|
+
cliFlag: "binaries-directory";
|
|
4
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
ssrName: "binariesDirectory";
|
|
6
|
+
docLink: string;
|
|
7
|
+
type: string | null;
|
|
8
|
+
getValue: ({ commandLine }: {
|
|
9
|
+
commandLine: Record<string, unknown>;
|
|
10
|
+
}) => {
|
|
11
|
+
source: string;
|
|
12
|
+
value: string | null;
|
|
13
|
+
};
|
|
14
|
+
setConfig: (value: string | null) => void;
|
|
15
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.binariesDirectoryOption = void 0;
|
|
4
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
const cliFlag = 'binaries-directory';
|
|
6
|
+
let currentDirectory = null;
|
|
7
|
+
exports.binariesDirectoryOption = {
|
|
8
|
+
name: 'Binaries Directory',
|
|
9
|
+
cliFlag,
|
|
10
|
+
description: () => ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: ["The directory where the platform-specific binaries and libraries that Remotion needs are located. Those include an ", (0, jsx_runtime_1.jsx)("code", { children: "ffmpeg" }), " and", ' ', (0, jsx_runtime_1.jsx)("code", { children: "ffprobe" }), " binary, a Rust binary for various tasks, and various shared libraries. If the value is set to ", (0, jsx_runtime_1.jsx)("code", { children: "null" }), ", which is the default, then the path of a platform-specific package located at", ' ', (0, jsx_runtime_1.jsx)("code", { children: "node_modules/@remotion/compositor-*" }), " is selected.", (0, jsx_runtime_1.jsx)("br", {}), "This option is useful in environments where Remotion is not officially supported to run like bundled serverless functions or Electron."] })),
|
|
11
|
+
ssrName: 'binariesDirectory',
|
|
12
|
+
docLink: 'https://www.remotion.dev/docs/renderer',
|
|
13
|
+
type: '',
|
|
14
|
+
getValue: ({ commandLine }) => {
|
|
15
|
+
if (commandLine[cliFlag] !== undefined) {
|
|
16
|
+
return {
|
|
17
|
+
source: 'cli',
|
|
18
|
+
value: commandLine[cliFlag],
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
if (currentDirectory !== null) {
|
|
22
|
+
return {
|
|
23
|
+
source: 'config',
|
|
24
|
+
value: currentDirectory,
|
|
25
|
+
};
|
|
26
|
+
}
|
|
27
|
+
return {
|
|
28
|
+
source: 'default',
|
|
29
|
+
value: null,
|
|
30
|
+
};
|
|
31
|
+
},
|
|
32
|
+
setConfig: (value) => {
|
|
33
|
+
currentDirectory = value;
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -6,13 +6,13 @@ export declare const colorSpaceOption: {
|
|
|
6
6
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
docLink: string;
|
|
8
8
|
ssrName: string;
|
|
9
|
-
type: "
|
|
9
|
+
type: "default" | "bt709" | "bt2020-ncl";
|
|
10
10
|
getValue: ({ commandLine }: {
|
|
11
11
|
commandLine: Record<string, unknown>;
|
|
12
12
|
}) => {
|
|
13
13
|
source: string;
|
|
14
|
-
value: "
|
|
14
|
+
value: "default" | "bt709" | "bt2020-ncl";
|
|
15
15
|
};
|
|
16
|
-
setConfig: (value: "
|
|
16
|
+
setConfig: (value: "default" | "bt709" | "bt2020-ncl") => void;
|
|
17
17
|
};
|
|
18
18
|
export declare const validateColorSpace: (option: unknown) => void;
|
package/dist/options/gl.d.ts
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
export declare const validOpenGlRenderers: readonly ["swangle", "angle", "egl", "swiftshader", "vulkan", "angle-egl"];
|
|
2
2
|
export type OpenGlRenderer = (typeof validOpenGlRenderers)[number];
|
|
3
3
|
export declare const DEFAULT_OPENGL_RENDERER: OpenGlRenderer | null;
|
|
4
|
-
export declare const getChromiumOpenGlRenderer: () => "
|
|
4
|
+
export declare const getChromiumOpenGlRenderer: () => "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null;
|
|
5
5
|
export declare const setChromiumOpenGlRenderer: (renderer: OpenGlRenderer) => void;
|
|
6
6
|
export declare const glOption: {
|
|
7
7
|
cliFlag: "gl";
|
|
8
8
|
docLink: string;
|
|
9
9
|
name: string;
|
|
10
|
-
type: "
|
|
10
|
+
type: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null;
|
|
11
11
|
ssrName: string;
|
|
12
12
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
getValue: ({ commandLine }: {
|
|
14
14
|
commandLine: Record<string, unknown>;
|
|
15
15
|
}) => {
|
|
16
|
-
value: "
|
|
16
|
+
value: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
|
|
17
17
|
source: string;
|
|
18
18
|
} | {
|
|
19
19
|
value: null;
|
package/dist/options/index.d.ts
CHANGED
|
@@ -114,17 +114,17 @@ export declare const allOptions: {
|
|
|
114
114
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
115
115
|
ssrName: string;
|
|
116
116
|
docLink: string;
|
|
117
|
-
type: "h264" | "h265" | "vp8" | "vp9" | "
|
|
117
|
+
type: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
118
118
|
getValue: ({ commandLine }: {
|
|
119
119
|
commandLine: Record<string, unknown>;
|
|
120
120
|
}, { compositionCodec, configFile, downloadName, outName, uiCodec, }: {
|
|
121
121
|
outName: string | null;
|
|
122
122
|
downloadName: string | null;
|
|
123
|
-
configFile: "h264" | "h265" | "vp8" | "vp9" | "
|
|
124
|
-
uiCodec: "h264" | "h265" | "vp8" | "vp9" | "
|
|
125
|
-
compositionCodec: "h264" | "h265" | "vp8" | "vp9" | "
|
|
123
|
+
configFile: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
124
|
+
uiCodec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
125
|
+
compositionCodec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
126
126
|
}) => {
|
|
127
|
-
value: "h264" | "h265" | "vp8" | "vp9" | "
|
|
127
|
+
value: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
128
128
|
source: string;
|
|
129
129
|
};
|
|
130
130
|
setConfig: (newCodec: import("..").CodecOrUndefined) => void;
|
|
@@ -150,7 +150,7 @@ export declare const allOptions: {
|
|
|
150
150
|
webhookCustomDataOption: {
|
|
151
151
|
name: string;
|
|
152
152
|
cliFlag: "webhook-custom-data";
|
|
153
|
-
description: (type: "
|
|
153
|
+
description: (type: "cli" | "ssr") => import("react/jsx-runtime").JSX.Element;
|
|
154
154
|
ssrName: "customData";
|
|
155
155
|
docLink: string;
|
|
156
156
|
type: Record<string, unknown> | null;
|
|
@@ -163,14 +163,14 @@ export declare const allOptions: {
|
|
|
163
163
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
164
164
|
docLink: string;
|
|
165
165
|
ssrName: string;
|
|
166
|
-
type: "
|
|
166
|
+
type: "default" | "bt709" | "bt2020-ncl";
|
|
167
167
|
getValue: ({ commandLine }: {
|
|
168
168
|
commandLine: Record<string, unknown>;
|
|
169
169
|
}) => {
|
|
170
170
|
source: string;
|
|
171
|
-
value: "
|
|
171
|
+
value: "default" | "bt709" | "bt2020-ncl";
|
|
172
172
|
};
|
|
173
|
-
setConfig: (value: "
|
|
173
|
+
setConfig: (value: "default" | "bt709" | "bt2020-ncl") => void;
|
|
174
174
|
};
|
|
175
175
|
deleteAfterOption: {
|
|
176
176
|
name: string;
|
|
@@ -224,19 +224,19 @@ export declare const allOptions: {
|
|
|
224
224
|
cliFlag: "gl";
|
|
225
225
|
docLink: string;
|
|
226
226
|
name: string;
|
|
227
|
-
type: "
|
|
227
|
+
type: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null;
|
|
228
228
|
ssrName: string;
|
|
229
229
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
230
230
|
getValue: ({ commandLine }: {
|
|
231
231
|
commandLine: Record<string, unknown>;
|
|
232
232
|
}) => {
|
|
233
|
-
value: "
|
|
233
|
+
value: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
|
|
234
234
|
source: string;
|
|
235
235
|
} | {
|
|
236
236
|
value: null;
|
|
237
237
|
source: string;
|
|
238
238
|
};
|
|
239
|
-
setConfig: (value: "
|
|
239
|
+
setConfig: (value: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null) => void;
|
|
240
240
|
};
|
|
241
241
|
enableLambdaInsights: {
|
|
242
242
|
name: string;
|
|
@@ -415,6 +415,21 @@ export declare const allOptions: {
|
|
|
415
415
|
};
|
|
416
416
|
setConfig: (value: boolean) => void;
|
|
417
417
|
};
|
|
418
|
+
binariesDirectoryOption: {
|
|
419
|
+
name: string;
|
|
420
|
+
cliFlag: "binaries-directory";
|
|
421
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
422
|
+
ssrName: "binariesDirectory";
|
|
423
|
+
docLink: string;
|
|
424
|
+
type: string | null;
|
|
425
|
+
getValue: ({ commandLine }: {
|
|
426
|
+
commandLine: Record<string, unknown>;
|
|
427
|
+
}) => {
|
|
428
|
+
source: string;
|
|
429
|
+
value: string | null;
|
|
430
|
+
};
|
|
431
|
+
setConfig: (value: string | null) => void;
|
|
432
|
+
};
|
|
418
433
|
};
|
|
419
434
|
export type AvailableOptions = keyof typeof allOptions;
|
|
420
435
|
export type TypeOfOption<Type> = Type extends AnyRemotionOption<infer X> ? X : never;
|
package/dist/options/index.js
CHANGED
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.allOptions = void 0;
|
|
4
4
|
const audio_bitrate_1 = require("./audio-bitrate");
|
|
5
5
|
const beep_on_finish_1 = require("./beep-on-finish");
|
|
6
|
+
const binaries_directory_1 = require("./binaries-directory");
|
|
6
7
|
const color_space_1 = require("./color-space");
|
|
7
8
|
const crf_1 = require("./crf");
|
|
8
9
|
const delete_after_1 = require("./delete-after");
|
|
@@ -54,4 +55,5 @@ exports.allOptions = {
|
|
|
54
55
|
delayRenderTimeoutInMillisecondsOption: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
55
56
|
headlessOption: headless_1.headlessOption,
|
|
56
57
|
overwriteOption: overwrite_1.overwriteOption,
|
|
58
|
+
binariesDirectoryOption: binaries_directory_1.binariesDirectoryOption,
|
|
57
59
|
};
|
package/dist/options/option.d.ts
CHANGED
|
@@ -108,14 +108,14 @@ export declare const optionsMap: {
|
|
|
108
108
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
109
109
|
docLink: string;
|
|
110
110
|
ssrName: string;
|
|
111
|
-
type: "
|
|
111
|
+
type: "default" | "bt709" | "bt2020-ncl";
|
|
112
112
|
getValue: ({ commandLine }: {
|
|
113
113
|
commandLine: Record<string, unknown>;
|
|
114
114
|
}) => {
|
|
115
115
|
source: string;
|
|
116
|
-
value: "
|
|
116
|
+
value: "default" | "bt709" | "bt2020-ncl";
|
|
117
117
|
};
|
|
118
|
-
setConfig: (value: "
|
|
118
|
+
setConfig: (value: "default" | "bt709" | "bt2020-ncl") => void;
|
|
119
119
|
};
|
|
120
120
|
readonly codec: {
|
|
121
121
|
name: string;
|
|
@@ -123,17 +123,17 @@ export declare const optionsMap: {
|
|
|
123
123
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
124
124
|
ssrName: string;
|
|
125
125
|
docLink: string;
|
|
126
|
-
type: "h264" | "h265" | "vp8" | "vp9" | "
|
|
126
|
+
type: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
127
127
|
getValue: ({ commandLine }: {
|
|
128
128
|
commandLine: Record<string, unknown>;
|
|
129
129
|
}, { compositionCodec, configFile, downloadName, outName, uiCodec, }: {
|
|
130
130
|
outName: string | null;
|
|
131
131
|
downloadName: string | null;
|
|
132
|
-
configFile: "h264" | "h265" | "vp8" | "vp9" | "
|
|
133
|
-
uiCodec: "h264" | "h265" | "vp8" | "vp9" | "
|
|
134
|
-
compositionCodec: "h264" | "h265" | "vp8" | "vp9" | "
|
|
132
|
+
configFile: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
133
|
+
uiCodec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
134
|
+
compositionCodec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | null;
|
|
135
135
|
}) => {
|
|
136
|
-
value: "h264" | "h265" | "vp8" | "vp9" | "
|
|
136
|
+
value: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
137
137
|
source: string;
|
|
138
138
|
};
|
|
139
139
|
setConfig: (newCodec: import("..").CodecOrUndefined) => void;
|
|
@@ -234,6 +234,21 @@ export declare const optionsMap: {
|
|
|
234
234
|
};
|
|
235
235
|
setConfig: (value: number) => void;
|
|
236
236
|
};
|
|
237
|
+
readonly binariesDirectory: {
|
|
238
|
+
name: string;
|
|
239
|
+
cliFlag: "binaries-directory";
|
|
240
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
241
|
+
ssrName: "binariesDirectory";
|
|
242
|
+
docLink: string;
|
|
243
|
+
type: string | null;
|
|
244
|
+
getValue: ({ commandLine }: {
|
|
245
|
+
commandLine: Record<string, unknown>;
|
|
246
|
+
}) => {
|
|
247
|
+
source: string;
|
|
248
|
+
value: string | null;
|
|
249
|
+
};
|
|
250
|
+
setConfig: (value: string | null) => void;
|
|
251
|
+
};
|
|
237
252
|
};
|
|
238
253
|
readonly renderStill: {
|
|
239
254
|
readonly offthreadVideoCacheSizeInBytes: {
|
|
@@ -299,6 +314,21 @@ export declare const optionsMap: {
|
|
|
299
314
|
};
|
|
300
315
|
setConfig: (value: number) => void;
|
|
301
316
|
};
|
|
317
|
+
readonly binariesDirectory: {
|
|
318
|
+
name: string;
|
|
319
|
+
cliFlag: "binaries-directory";
|
|
320
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
321
|
+
ssrName: "binariesDirectory";
|
|
322
|
+
docLink: string;
|
|
323
|
+
type: string | null;
|
|
324
|
+
getValue: ({ commandLine }: {
|
|
325
|
+
commandLine: Record<string, unknown>;
|
|
326
|
+
}) => {
|
|
327
|
+
source: string;
|
|
328
|
+
value: string | null;
|
|
329
|
+
};
|
|
330
|
+
setConfig: (value: string | null) => void;
|
|
331
|
+
};
|
|
302
332
|
};
|
|
303
333
|
readonly getCompositions: {
|
|
304
334
|
readonly offthreadVideoCacheSizeInBytes: {
|
|
@@ -349,6 +379,21 @@ export declare const optionsMap: {
|
|
|
349
379
|
};
|
|
350
380
|
setConfig: (value: number) => void;
|
|
351
381
|
};
|
|
382
|
+
readonly binariesDirectory: {
|
|
383
|
+
name: string;
|
|
384
|
+
cliFlag: "binaries-directory";
|
|
385
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
386
|
+
ssrName: "binariesDirectory";
|
|
387
|
+
docLink: string;
|
|
388
|
+
type: string | null;
|
|
389
|
+
getValue: ({ commandLine }: {
|
|
390
|
+
commandLine: Record<string, unknown>;
|
|
391
|
+
}) => {
|
|
392
|
+
source: string;
|
|
393
|
+
value: string | null;
|
|
394
|
+
};
|
|
395
|
+
setConfig: (value: string | null) => void;
|
|
396
|
+
};
|
|
352
397
|
};
|
|
353
398
|
readonly selectComposition: {
|
|
354
399
|
readonly offthreadVideoCacheSizeInBytes: {
|
|
@@ -399,6 +444,21 @@ export declare const optionsMap: {
|
|
|
399
444
|
};
|
|
400
445
|
setConfig: (value: number) => void;
|
|
401
446
|
};
|
|
447
|
+
readonly binariesDirectory: {
|
|
448
|
+
name: string;
|
|
449
|
+
cliFlag: "binaries-directory";
|
|
450
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
451
|
+
ssrName: "binariesDirectory";
|
|
452
|
+
docLink: string;
|
|
453
|
+
type: string | null;
|
|
454
|
+
getValue: ({ commandLine }: {
|
|
455
|
+
commandLine: Record<string, unknown>;
|
|
456
|
+
}) => {
|
|
457
|
+
source: string;
|
|
458
|
+
value: string | null;
|
|
459
|
+
};
|
|
460
|
+
setConfig: (value: string | null) => void;
|
|
461
|
+
};
|
|
402
462
|
};
|
|
403
463
|
readonly renderFrames: {
|
|
404
464
|
readonly offthreadVideoCacheSizeInBytes: {
|
|
@@ -464,6 +524,21 @@ export declare const optionsMap: {
|
|
|
464
524
|
};
|
|
465
525
|
setConfig: (value: number) => void;
|
|
466
526
|
};
|
|
527
|
+
readonly binariesDirectory: {
|
|
528
|
+
name: string;
|
|
529
|
+
cliFlag: "binaries-directory";
|
|
530
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
531
|
+
ssrName: "binariesDirectory";
|
|
532
|
+
docLink: string;
|
|
533
|
+
type: string | null;
|
|
534
|
+
getValue: ({ commandLine }: {
|
|
535
|
+
commandLine: Record<string, unknown>;
|
|
536
|
+
}) => {
|
|
537
|
+
source: string;
|
|
538
|
+
value: string | null;
|
|
539
|
+
};
|
|
540
|
+
setConfig: (value: string | null) => void;
|
|
541
|
+
};
|
|
467
542
|
};
|
|
468
543
|
readonly renderMediaOnLambda: {
|
|
469
544
|
readonly offthreadVideoCacheSizeInBytes: {
|
|
@@ -613,14 +688,14 @@ export declare const optionsMap: {
|
|
|
613
688
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
614
689
|
docLink: string;
|
|
615
690
|
ssrName: string;
|
|
616
|
-
type: "
|
|
691
|
+
type: "default" | "bt709" | "bt2020-ncl";
|
|
617
692
|
getValue: ({ commandLine }: {
|
|
618
693
|
commandLine: Record<string, unknown>;
|
|
619
694
|
}) => {
|
|
620
695
|
source: string;
|
|
621
|
-
value: "
|
|
696
|
+
value: "default" | "bt709" | "bt2020-ncl";
|
|
622
697
|
};
|
|
623
|
-
setConfig: (value: "
|
|
698
|
+
setConfig: (value: "default" | "bt709" | "bt2020-ncl") => void;
|
|
624
699
|
};
|
|
625
700
|
readonly muted: {
|
|
626
701
|
name: string;
|
|
@@ -859,14 +934,14 @@ export declare const optionsMap: {
|
|
|
859
934
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
860
935
|
docLink: string;
|
|
861
936
|
ssrName: string;
|
|
862
|
-
type: "
|
|
937
|
+
type: "default" | "bt709" | "bt2020-ncl";
|
|
863
938
|
getValue: ({ commandLine }: {
|
|
864
939
|
commandLine: Record<string, unknown>;
|
|
865
940
|
}) => {
|
|
866
941
|
source: string;
|
|
867
|
-
value: "
|
|
942
|
+
value: "default" | "bt709" | "bt2020-ncl";
|
|
868
943
|
};
|
|
869
|
-
setConfig: (value: "
|
|
944
|
+
setConfig: (value: "default" | "bt709" | "bt2020-ncl") => void;
|
|
870
945
|
};
|
|
871
946
|
readonly audioBitrate: {
|
|
872
947
|
name: string;
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.optionsMap = void 0;
|
|
4
4
|
const audio_bitrate_1 = require("./audio-bitrate");
|
|
5
|
+
const binaries_directory_1 = require("./binaries-directory");
|
|
5
6
|
const color_space_1 = require("./color-space");
|
|
6
7
|
const crf_1 = require("./crf");
|
|
7
8
|
const delete_after_1 = require("./delete-after");
|
|
@@ -35,28 +36,33 @@ exports.optionsMap = {
|
|
|
35
36
|
muted: mute_1.mutedOption,
|
|
36
37
|
logLevel: log_level_1.logLevelOption,
|
|
37
38
|
timeoutInMilliseconds: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
39
|
+
binariesDirectory: binaries_directory_1.binariesDirectoryOption,
|
|
38
40
|
},
|
|
39
41
|
renderStill: {
|
|
40
42
|
offthreadVideoCacheSizeInBytes: offthreadvideo_cache_size_1.offthreadVideoCacheSizeInBytesOption,
|
|
41
43
|
jpegQuality: jpeg_quality_1.jpegQualityOption,
|
|
42
44
|
logLevel: log_level_1.logLevelOption,
|
|
43
45
|
timeoutInMilliseconds: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
46
|
+
binariesDirectory: binaries_directory_1.binariesDirectoryOption,
|
|
44
47
|
},
|
|
45
48
|
getCompositions: {
|
|
46
49
|
offthreadVideoCacheSizeInBytes: offthreadvideo_cache_size_1.offthreadVideoCacheSizeInBytesOption,
|
|
47
50
|
logLevel: log_level_1.logLevelOption,
|
|
48
51
|
timeoutInMilliseconds: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
52
|
+
binariesDirectory: binaries_directory_1.binariesDirectoryOption,
|
|
49
53
|
},
|
|
50
54
|
selectComposition: {
|
|
51
55
|
offthreadVideoCacheSizeInBytes: offthreadvideo_cache_size_1.offthreadVideoCacheSizeInBytesOption,
|
|
52
56
|
logLevel: log_level_1.logLevelOption,
|
|
53
57
|
timeoutInMilliseconds: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
58
|
+
binariesDirectory: binaries_directory_1.binariesDirectoryOption,
|
|
54
59
|
},
|
|
55
60
|
renderFrames: {
|
|
56
61
|
offthreadVideoCacheSizeInBytes: offthreadvideo_cache_size_1.offthreadVideoCacheSizeInBytesOption,
|
|
57
62
|
jpegQuality: jpeg_quality_1.jpegQualityOption,
|
|
58
63
|
logLevel: log_level_1.logLevelOption,
|
|
59
64
|
timeoutInMilliseconds: timeout_1.delayRenderTimeoutInMillisecondsOption,
|
|
65
|
+
binariesDirectory: binaries_directory_1.binariesDirectoryOption,
|
|
60
66
|
},
|
|
61
67
|
renderMediaOnLambda: {
|
|
62
68
|
offthreadVideoCacheSizeInBytes: offthreadvideo_cache_size_1.offthreadVideoCacheSizeInBytesOption,
|
|
@@ -6,7 +6,7 @@ export declare const videoCodecOption: {
|
|
|
6
6
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
ssrName: string;
|
|
8
8
|
docLink: string;
|
|
9
|
-
type: "h264" | "h265" | "vp8" | "vp9" | "
|
|
9
|
+
type: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
10
10
|
getValue: ({ commandLine }: {
|
|
11
11
|
commandLine: Record<string, unknown>;
|
|
12
12
|
}, { compositionCodec, configFile, downloadName, outName, uiCodec, }: {
|
package/dist/pixel-format.d.ts
CHANGED
|
@@ -2,5 +2,5 @@ import type { Codec } from './codec';
|
|
|
2
2
|
export declare const validPixelFormats: readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"];
|
|
3
3
|
export type PixelFormat = (typeof validPixelFormats)[number];
|
|
4
4
|
export declare const DEFAULT_PIXEL_FORMAT: PixelFormat;
|
|
5
|
-
export declare const validPixelFormatsForCodec: (codec: Codec) => readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"] | ("yuv420p" | "
|
|
5
|
+
export declare const validPixelFormatsForCodec: (codec: Codec) => readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"] | ("yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le")[];
|
|
6
6
|
export declare const validateSelectedPixelFormatAndCodecCombination: (pixelFormat: PixelFormat | undefined, codec: Codec) => undefined;
|
package/dist/prepare-server.d.ts
CHANGED
|
@@ -19,8 +19,9 @@ type PrepareServerOptions = {
|
|
|
19
19
|
logLevel: LogLevel;
|
|
20
20
|
indent: boolean;
|
|
21
21
|
offthreadVideoCacheSizeInBytes: number | null;
|
|
22
|
+
binariesDirectory: string | null;
|
|
22
23
|
};
|
|
23
|
-
export declare const prepareServer: ({ webpackConfigOrServeUrl, port, remotionRoot, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, }: PrepareServerOptions) => Promise<RemotionServer>;
|
|
24
|
+
export declare const prepareServer: ({ webpackConfigOrServeUrl, port, remotionRoot, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, binariesDirectory, }: PrepareServerOptions) => Promise<RemotionServer>;
|
|
24
25
|
export declare const makeOrReuseServer: (server: RemotionServer | undefined, config: PrepareServerOptions, { onDownload, onError, }: {
|
|
25
26
|
onError: (err: Error) => void;
|
|
26
27
|
onDownload: RenderMediaOnDownload | null;
|
package/dist/prepare-server.js
CHANGED
|
@@ -15,7 +15,7 @@ const logger_1 = require("./logger");
|
|
|
15
15
|
const serve_static_1 = require("./serve-static");
|
|
16
16
|
const symbolicate_stacktrace_1 = require("./symbolicate-stacktrace");
|
|
17
17
|
const wait_for_symbolication_error_to_be_done_1 = require("./wait-for-symbolication-error-to-be-done");
|
|
18
|
-
const prepareServer = async ({ webpackConfigOrServeUrl, port, remotionRoot, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, }) => {
|
|
18
|
+
const prepareServer = async ({ webpackConfigOrServeUrl, port, remotionRoot, concurrency, logLevel, indent, offthreadVideoCacheSizeInBytes, binariesDirectory, }) => {
|
|
19
19
|
const downloadMap = (0, download_map_1.makeDownloadMap)();
|
|
20
20
|
logger_1.Log.verbose({ indent, logLevel }, 'Created directory for temporary files', downloadMap.assetDir);
|
|
21
21
|
if ((0, is_serve_url_1.isServeUrl)(webpackConfigOrServeUrl)) {
|
|
@@ -27,6 +27,7 @@ const prepareServer = async ({ webpackConfigOrServeUrl, port, remotionRoot, conc
|
|
|
27
27
|
logLevel,
|
|
28
28
|
indent,
|
|
29
29
|
offthreadVideoCacheSizeInBytes,
|
|
30
|
+
binariesDirectory,
|
|
30
31
|
});
|
|
31
32
|
let remoteSourceMap = null;
|
|
32
33
|
(0, symbolicate_stacktrace_1.getSourceMapFromRemoteUrl)((0, get_bundle_url_from_serve_url_1.getBundleMapUrlFromServeUrl)(webpackConfigOrServeUrl))
|
|
@@ -72,6 +73,7 @@ const prepareServer = async ({ webpackConfigOrServeUrl, port, remotionRoot, conc
|
|
|
72
73
|
logLevel,
|
|
73
74
|
indent,
|
|
74
75
|
offthreadVideoCacheSizeInBytes,
|
|
76
|
+
binariesDirectory,
|
|
75
77
|
});
|
|
76
78
|
return Promise.resolve({
|
|
77
79
|
closeServer: async (force) => {
|
|
@@ -8,8 +8,14 @@ const ffmpeg_filter_file_1 = require("./ffmpeg-filter-file");
|
|
|
8
8
|
const p_limit_1 = require("./p-limit");
|
|
9
9
|
const resolve_asset_src_1 = require("./resolve-asset-src");
|
|
10
10
|
const sample_rate_1 = require("./sample-rate");
|
|
11
|
-
const preprocessAudioTrackUnlimited = async ({ outName, asset, expectedFrames, fps, downloadMap, indent, logLevel, }) => {
|
|
12
|
-
const { channels, duration } = await (0, get_audio_channels_1.getAudioChannelsAndDuration)(
|
|
11
|
+
const preprocessAudioTrackUnlimited = async ({ outName, asset, expectedFrames, fps, downloadMap, indent, logLevel, binariesDirectory, }) => {
|
|
12
|
+
const { channels, duration } = await (0, get_audio_channels_1.getAudioChannelsAndDuration)({
|
|
13
|
+
downloadMap,
|
|
14
|
+
src: (0, resolve_asset_src_1.resolveAssetSrc)(asset.src),
|
|
15
|
+
indent,
|
|
16
|
+
logLevel,
|
|
17
|
+
binariesDirectory,
|
|
18
|
+
});
|
|
13
19
|
const filter = (0, calculate_ffmpeg_filters_1.calculateFfmpegFilter)({
|
|
14
20
|
asset,
|
|
15
21
|
durationInFrames: expectedFrames,
|
|
@@ -29,7 +35,7 @@ const preprocessAudioTrackUnlimited = async ({ outName, asset, expectedFrames, f
|
|
|
29
35
|
['-ar', String(sample_rate_1.DEFAULT_SAMPLE_RATE)],
|
|
30
36
|
['-y', outName],
|
|
31
37
|
].flat(2);
|
|
32
|
-
await (0, call_ffmpeg_1.callFf)({ bin: 'ffmpeg', args, indent, logLevel });
|
|
38
|
+
await (0, call_ffmpeg_1.callFf)({ bin: 'ffmpeg', args, indent, logLevel, binariesDirectory });
|
|
33
39
|
cleanup();
|
|
34
40
|
return { outName, filter };
|
|
35
41
|
};
|
|
@@ -37,6 +37,7 @@ type PreStitcherOptions = {
|
|
|
37
37
|
encodingBufferSize: string | null;
|
|
38
38
|
indent: boolean;
|
|
39
39
|
colorSpace: ColorSpace;
|
|
40
|
+
binariesDirectory: string | null;
|
|
40
41
|
};
|
|
41
42
|
export declare const prespawnFfmpeg: (options: PreStitcherOptions) => {
|
|
42
43
|
task: import("execa").ExecaChildProcess<string>;
|