@remotion/renderer 4.0.104 → 4.0.105
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/client.d.ts +1 -1
- package/dist/combine-videos.js +3 -0
- package/dist/get-extension-from-codec.d.ts +2 -2
- package/dist/index.d.ts +5 -3
- package/dist/options/color-space.d.ts +1 -1
- package/dist/options/gl.d.ts +1 -1
- package/dist/options/index.d.ts +1 -1
- package/dist/pixel-format.d.ts +1 -1
- package/dist/pure.d.ts +3 -3
- package/dist/screenshot-task.d.ts +0 -1
- package/dist/screenshot-task.js +6 -1
- package/dist/stitch-frames-to-video.js +3 -33
- package/dist/take-frame-and-compose.d.ts +1 -0
- package/dist/validate-output-filename.d.ts +1 -1
- package/package.json +9 -9
- package/dist/check-apple-silicon.d.ts +0 -3
- package/dist/check-apple-silicon.js +0 -42
package/dist/client.d.ts
CHANGED
|
@@ -316,7 +316,7 @@ export declare const BrowserSafeApis: {
|
|
|
316
316
|
cliFlag: "gl";
|
|
317
317
|
docLink: string;
|
|
318
318
|
name: string;
|
|
319
|
-
type: "
|
|
319
|
+
type: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
|
|
320
320
|
ssrName: string;
|
|
321
321
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
322
322
|
};
|
package/dist/combine-videos.js
CHANGED
|
@@ -4,6 +4,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.combineVideos = void 0;
|
|
5
5
|
const node_fs_1 = require("node:fs");
|
|
6
6
|
const node_path_1 = require("node:path");
|
|
7
|
+
const version_1 = require("remotion/version");
|
|
7
8
|
const audio_codec_1 = require("./audio-codec");
|
|
8
9
|
const call_ffmpeg_1 = require("./call-ffmpeg");
|
|
9
10
|
const convert_number_of_gif_loops_to_ffmpeg_1 = require("./convert-number-of-gif-loops-to-ffmpeg");
|
|
@@ -43,6 +44,8 @@ const combineVideos = async (options) => {
|
|
|
43
44
|
audioBitrate ? audioBitrate : '320k',
|
|
44
45
|
codec === 'h264' ? '-movflags' : null,
|
|
45
46
|
codec === 'h264' ? 'faststart' : null,
|
|
47
|
+
`-metadata`,
|
|
48
|
+
`comment=Made with Remotion ${version_1.VERSION}`,
|
|
46
49
|
'-y',
|
|
47
50
|
output,
|
|
48
51
|
].filter(truthy_1.truthy);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { AudioCodec } from './audio-codec';
|
|
2
2
|
import type { Codec } from './codec';
|
|
3
3
|
import type { FileExtension } from './file-extensions';
|
|
4
|
-
export declare const getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "
|
|
5
|
-
export declare const makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "
|
|
4
|
+
export declare const getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">(codec: T, audioCodec: AudioCodec | null) => FileExtension;
|
|
5
|
+
export declare const makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif")[]>;
|
|
6
6
|
export declare const defaultCodecsForFileExtension: Record<FileExtension, Codec>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
/// <reference types="node" />
|
|
1
3
|
import execa from 'execa';
|
|
2
4
|
import { HeadlessBrowser } from './browser/Browser';
|
|
3
5
|
import { SymbolicateableError } from './error-handling/symbolicateable-error';
|
|
@@ -135,8 +137,8 @@ export declare const RenderInternals: {
|
|
|
135
137
|
validPixelFormats: readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"];
|
|
136
138
|
DEFAULT_BROWSER: "chrome";
|
|
137
139
|
validateFrameRange: (frameRange: import("./frame-range").FrameRange | null) => void;
|
|
138
|
-
DEFAULT_OPENGL_RENDERER: "
|
|
139
|
-
validateOpenGlRenderer: (option: "
|
|
140
|
+
DEFAULT_OPENGL_RENDERER: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null;
|
|
141
|
+
validateOpenGlRenderer: (option: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null) => "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl" | null;
|
|
140
142
|
validCodecs: readonly ["h264", "h265", "vp8", "vp9", "mp3", "aac", "wav", "prores", "h264-mkv", "gif"];
|
|
141
143
|
DEFAULT_PIXEL_FORMAT: "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le";
|
|
142
144
|
validateJpegQuality: (q: number | undefined) => void;
|
|
@@ -311,7 +313,7 @@ export declare const RenderInternals: {
|
|
|
311
313
|
};
|
|
312
314
|
makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif")[]>;
|
|
313
315
|
defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">;
|
|
314
|
-
getExecutablePath: (type: "
|
|
316
|
+
getExecutablePath: (type: "ffmpeg" | "ffprobe" | "compositor", indent: boolean, logLevel: "verbose" | "info" | "warn" | "error") => string;
|
|
315
317
|
callFf: ({ args, bin, indent, logLevel, options, }: {
|
|
316
318
|
bin: "ffmpeg" | "ffprobe";
|
|
317
319
|
args: (string | null)[];
|
|
@@ -6,6 +6,6 @@ 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: "bt709" | "bt2020-ncl" | "default";
|
|
10
10
|
};
|
|
11
11
|
export declare const validateColorSpace: (option: unknown) => void;
|
package/dist/options/gl.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export declare const glOption: {
|
|
|
3
3
|
cliFlag: "gl";
|
|
4
4
|
docLink: string;
|
|
5
5
|
name: string;
|
|
6
|
-
type: "
|
|
6
|
+
type: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
|
|
7
7
|
ssrName: string;
|
|
8
8
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
9
9
|
};
|
package/dist/options/index.d.ts
CHANGED
|
@@ -115,7 +115,7 @@ export declare const allOptions: {
|
|
|
115
115
|
cliFlag: "gl";
|
|
116
116
|
docLink: string;
|
|
117
117
|
name: string;
|
|
118
|
-
type: "
|
|
118
|
+
type: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
|
|
119
119
|
ssrName: string;
|
|
120
120
|
description: () => import("react/jsx-runtime").JSX.Element;
|
|
121
121
|
};
|
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" | "yuv422p" | "yuv444p" | "yuva420p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le")[];
|
|
6
6
|
export declare const validateSelectedPixelFormatAndCodecCombination: (pixelFormat: PixelFormat | undefined, codec: Codec) => undefined;
|
package/dist/pure.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export declare const NoReactAPIs: {
|
|
2
2
|
wrapWithErrorHandling: <A extends unknown[], R>(fn: (...args: A) => Promise<R>) => (...args: A) => Promise<R>;
|
|
3
3
|
getExtensionOfFilename: (filename: string | null) => string | null;
|
|
4
|
-
getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "
|
|
5
|
-
validateOutputFilename: <T_1 extends "h264" | "h265" | "vp8" | "vp9" | "
|
|
4
|
+
getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">(codec: T, audioCodec: "opus" | "aac" | "mp3" | "pcm-16" | null) => import("./file-extensions").FileExtension;
|
|
5
|
+
validateOutputFilename: <T_1 extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
|
|
6
6
|
codec: T_1;
|
|
7
|
-
audioCodec: "
|
|
7
|
+
audioCodec: "opus" | "aac" | "mp3" | "pcm-16" | null;
|
|
8
8
|
extension: string;
|
|
9
9
|
preferLossless: boolean;
|
|
10
10
|
}) => void;
|
package/dist/screenshot-task.js
CHANGED
|
@@ -56,7 +56,12 @@ const screenshotTask = async ({ format, height, omitBackground, page, width, pat
|
|
|
56
56
|
width,
|
|
57
57
|
},
|
|
58
58
|
captureBeyondViewport: true,
|
|
59
|
-
optimizeForSpeed:
|
|
59
|
+
optimizeForSpeed: false,
|
|
60
|
+
// We find that there is a 0.1% framedrop when rendering under memory pressure
|
|
61
|
+
// which can be circumvented by disabling this option on Lambda.
|
|
62
|
+
// To be determined: Is this a problem with Lambda, Linux, or the Chrome version
|
|
63
|
+
// we are using on Lambda?
|
|
64
|
+
fromSurface: process.platform !== 'linux',
|
|
60
65
|
});
|
|
61
66
|
result = value;
|
|
62
67
|
}
|
|
@@ -1,35 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
4
|
};
|
|
28
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
6
|
exports.stitchFramesToVideo = exports.internalStitchFramesToVideo = void 0;
|
|
30
|
-
const node_fs_1 =
|
|
7
|
+
const node_fs_1 = require("node:fs");
|
|
31
8
|
const node_path_1 = __importDefault(require("node:path"));
|
|
32
9
|
const no_react_1 = require("remotion/no-react");
|
|
10
|
+
const version_1 = require("remotion/version");
|
|
33
11
|
const calculate_asset_positions_1 = require("./assets/calculate-asset-positions");
|
|
34
12
|
const convert_assets_to_file_urls_1 = require("./assets/convert-assets-to-file-urls");
|
|
35
13
|
const download_and_map_assets_to_file_1 = require("./assets/download-and-map-assets-to-file");
|
|
@@ -55,10 +33,6 @@ const truthy_1 = require("./truthy");
|
|
|
55
33
|
const validate_1 = require("./validate");
|
|
56
34
|
const validate_even_dimensions_with_codec_1 = require("./validate-even-dimensions-with-codec");
|
|
57
35
|
const validate_videobitrate_1 = require("./validate-videobitrate");
|
|
58
|
-
const packageJsonPath = node_path_1.default.join(__dirname, '..', 'package.json');
|
|
59
|
-
const packageJson = node_fs_1.default.existsSync(packageJsonPath)
|
|
60
|
-
? JSON.parse(node_fs_1.default.readFileSync(packageJsonPath, 'utf-8'))
|
|
61
|
-
: null;
|
|
62
36
|
const getAssetsData = async ({ assets, onDownload, fps, expectedFrames, logLevel, onProgress, downloadMap, remotionRoot, indent, }) => {
|
|
63
37
|
const fileUrlAssets = await (0, convert_assets_to_file_urls_1.convertAssetsToFileUrls)({
|
|
64
38
|
assets,
|
|
@@ -277,11 +251,7 @@ const innerStitchFramesToVideo = async ({ assetsInfo, audioBitrate, audioCodec,
|
|
|
277
251
|
resolvedAudioCodec === 'aac' ? '18000' : null,
|
|
278
252
|
// Ignore metadata that may come from remote media
|
|
279
253
|
['-map_metadata', '-1'],
|
|
280
|
-
[
|
|
281
|
-
'-metadata',
|
|
282
|
-
`comment=` +
|
|
283
|
-
[`Made with Remotion`, packageJson ? packageJson.version : null].join(' '),
|
|
284
|
-
],
|
|
254
|
+
['-metadata', `comment=Made with Remotion ${version_1.VERSION}`],
|
|
285
255
|
force ? '-y' : null,
|
|
286
256
|
outputLocation !== null && outputLocation !== void 0 ? outputLocation : tempFile,
|
|
287
257
|
];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { AudioCodec } from './audio-codec';
|
|
2
|
-
export declare const validateOutputFilename: <T extends "h264" | "h265" | "vp8" | "vp9" | "
|
|
2
|
+
export declare const validateOutputFilename: <T extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
|
|
3
3
|
codec: T;
|
|
4
4
|
audioCodec: AudioCodec | null;
|
|
5
5
|
extension: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/renderer",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.105",
|
|
4
4
|
"description": "Renderer for Remotion",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"extract-zip": "2.0.1",
|
|
19
19
|
"source-map": "^0.8.0-beta.0",
|
|
20
20
|
"ws": "8.7.0",
|
|
21
|
-
"remotion": "4.0.
|
|
21
|
+
"remotion": "4.0.105"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"react": ">=16.8.0",
|
|
@@ -40,13 +40,13 @@
|
|
|
40
40
|
"vitest": "0.31.1"
|
|
41
41
|
},
|
|
42
42
|
"optionalDependencies": {
|
|
43
|
-
"@remotion/compositor-
|
|
44
|
-
"@remotion/compositor-
|
|
45
|
-
"@remotion/compositor-
|
|
46
|
-
"@remotion/compositor-linux-
|
|
47
|
-
"@remotion/compositor-linux-x64-gnu": "4.0.
|
|
48
|
-
"@remotion/compositor-
|
|
49
|
-
"@remotion/compositor-win32-x64-msvc": "4.0.
|
|
43
|
+
"@remotion/compositor-darwin-arm64": "4.0.105",
|
|
44
|
+
"@remotion/compositor-linux-arm64-gnu": "4.0.105",
|
|
45
|
+
"@remotion/compositor-darwin-x64": "4.0.105",
|
|
46
|
+
"@remotion/compositor-linux-arm64-musl": "4.0.105",
|
|
47
|
+
"@remotion/compositor-linux-x64-gnu": "4.0.105",
|
|
48
|
+
"@remotion/compositor-linux-x64-musl": "4.0.105",
|
|
49
|
+
"@remotion/compositor-win32-x64-msvc": "4.0.105"
|
|
50
50
|
},
|
|
51
51
|
"keywords": [
|
|
52
52
|
"remotion",
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.checkNodeVersionAndWarnAboutRosetta = exports.gLibCErrorMessage = void 0;
|
|
4
|
-
const logger_1 = require("./logger");
|
|
5
|
-
const gLibCErrorMessage = (libCString) => {
|
|
6
|
-
const split = libCString.split('.');
|
|
7
|
-
if (split.length !== 2) {
|
|
8
|
-
return null;
|
|
9
|
-
}
|
|
10
|
-
if (split[0] === '2' && Number(split[1]) >= 35) {
|
|
11
|
-
return null;
|
|
12
|
-
}
|
|
13
|
-
if (Number(split[0]) > 2) {
|
|
14
|
-
return null;
|
|
15
|
-
}
|
|
16
|
-
return `Rendering videos requires glibc 2.35 or higher. Your system has glibc ${libCString}.`;
|
|
17
|
-
};
|
|
18
|
-
exports.gLibCErrorMessage = gLibCErrorMessage;
|
|
19
|
-
const checkLibCRequirement = (logLevel, indent) => {
|
|
20
|
-
const { report } = process;
|
|
21
|
-
if (report) {
|
|
22
|
-
// @ts-expect-error no types
|
|
23
|
-
const { glibcVersionRuntime } = report.getReport().header;
|
|
24
|
-
if (!glibcVersionRuntime) {
|
|
25
|
-
return;
|
|
26
|
-
}
|
|
27
|
-
const error = (0, exports.gLibCErrorMessage)(glibcVersionRuntime);
|
|
28
|
-
if (error) {
|
|
29
|
-
logger_1.Log.warn({ logLevel, indent }, error);
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
const checkNodeVersionAndWarnAboutRosetta = (logLevel, indent) => {
|
|
34
|
-
const version = process.version.replace('v', '').split('.');
|
|
35
|
-
const majorVersion = Number(version[0]);
|
|
36
|
-
const requiredNodeVersion = 16;
|
|
37
|
-
if (majorVersion < 16) {
|
|
38
|
-
throw new Error(`Remotion requires at least Node ${requiredNodeVersion}. You currently have ${process.version}. Update your node version to ${requiredNodeVersion} to use Remotion.`);
|
|
39
|
-
}
|
|
40
|
-
checkLibCRequirement(logLevel, indent);
|
|
41
|
-
};
|
|
42
|
-
exports.checkNodeVersionAndWarnAboutRosetta = checkNodeVersionAndWarnAboutRosetta;
|