remotion 3.1.4 → 3.1.7
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/.turbo/turbo-build.log +5 -5
- package/dist/Composition.js +1 -1
- package/dist/CompositionManager.d.ts +0 -6
- package/dist/Still.d.ts +0 -1
- package/dist/audio/Audio.d.ts +2 -2
- package/dist/audio/AudioForDevelopment.d.ts +2 -2
- package/dist/audio/AudioForDevelopment.js +10 -1
- package/dist/audio/AudioForRendering.d.ts +1 -1
- package/dist/audio/shared-audio-tags.d.ts +3 -2
- package/dist/audio/shared-audio-tags.js +83 -40
- package/dist/config/index.d.ts +6 -2
- package/dist/config/index.js +5 -0
- package/dist/config/log.d.ts +1 -1
- package/dist/config/output-location.d.ts +2 -0
- package/dist/config/output-location.js +16 -0
- package/dist/config.d.ts +188 -0
- package/dist/config.js +21 -0
- package/dist/delay-render.js +4 -4
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -2
- package/dist/internals.d.ts +12 -94
- package/dist/internals.js +3 -93
- package/dist/spring/measure-spring.js +1 -1
- package/dist/validation/validate-fps.d.ts +1 -2
- package/dist/validation/validate-fps.js +3 -3
- package/dist/video/Video.d.ts +2 -2
- package/dist/video/VideoForDevelopment.d.ts +2 -2
- package/dist/video/VideoForRendering.d.ts +1 -1
- package/package.json +2 -2
- package/dist/config/bundle-out-dir.d.ts +0 -2
- package/dist/config/bundle-out-dir.js +0 -12
- package/dist/config/every-nth-file.d.ts +0 -2
- package/dist/config/every-nth-file.js +0 -12
- package/dist/config/loop.d.ts +0 -4
- package/dist/config/loop.js +0 -18
- package/dist/config/public-path.d.ts +0 -2
- package/dist/config/public-path.js +0 -12
- package/dist/config/skip-n-frames.d.ts +0 -2
- package/dist/config/skip-n-frames.js +0 -12
- package/dist/initial-frame.d.ts +0 -2
- package/dist/initial-frame.js +0 -12
- package/dist/interpolateColors.d.ts +0 -5
- package/dist/interpolateColors.js +0 -401
- package/dist/preload.d.ts +0 -7
- package/dist/preload.js +0 -39
- package/dist/sequencing/index.d.ts +0 -19
- package/dist/sequencing/index.js +0 -123
- package/dist/use-frame.d.ts +0 -7
- package/dist/use-frame.js +0 -25
package/dist/config.d.ts
ADDED
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The configuration has moved to @remotion/cli.
|
|
3
|
+
* For the moment the type definitions are going to stay here
|
|
4
|
+
*/
|
|
5
|
+
declare type Concurrency = number | null;
|
|
6
|
+
import type { Configuration } from 'webpack';
|
|
7
|
+
declare type WebpackConfiguration = Configuration;
|
|
8
|
+
declare type WebpackOverrideFn = (currentConfiguration: WebpackConfiguration) => WebpackConfiguration;
|
|
9
|
+
declare type BrowserExecutable = string | null;
|
|
10
|
+
declare type FrameRange = number | [number, number];
|
|
11
|
+
declare type FfmpegExecutable = string | null;
|
|
12
|
+
declare type Loop = number | null;
|
|
13
|
+
declare type CodecOrUndefined = 'h264' | 'h265' | 'vp8' | 'vp9' | 'mp3' | 'aac' | 'wav' | 'prores' | 'h264-mkv' | 'gif' | undefined;
|
|
14
|
+
declare type Crf = number | undefined;
|
|
15
|
+
export declare type ConfigType = {
|
|
16
|
+
readonly Preview: {
|
|
17
|
+
/**
|
|
18
|
+
* Change the maximum amount of tracks that are shown in the timeline.
|
|
19
|
+
* @param maxTracks The maximum amount of timeline tracks that you would like to show.
|
|
20
|
+
* @default 15
|
|
21
|
+
*/
|
|
22
|
+
readonly setMaxTimelineTracks: (maxTracks: number) => void;
|
|
23
|
+
};
|
|
24
|
+
readonly Bundling: {
|
|
25
|
+
/**
|
|
26
|
+
* Pass in a function which takes the current Webpack config
|
|
27
|
+
* and return a modified Webpack configuration.
|
|
28
|
+
* Docs: http://remotion.dev/docs/webpack
|
|
29
|
+
*/
|
|
30
|
+
readonly overrideWebpackConfig: (fn: WebpackOverrideFn) => void;
|
|
31
|
+
/**
|
|
32
|
+
* Whether Webpack bundles should be cached to make
|
|
33
|
+
* subsequent renders faster. Default: true
|
|
34
|
+
*/
|
|
35
|
+
readonly setCachingEnabled: (flag: boolean) => void;
|
|
36
|
+
/**
|
|
37
|
+
* Define on which port Remotion should start it's HTTP servers during preview and rendering.
|
|
38
|
+
* By default, Remotion will try to find a free port.
|
|
39
|
+
* If you specify a port, but it's not available, Remotion will throw an error.
|
|
40
|
+
*/
|
|
41
|
+
readonly setPort: (port: number | undefined) => void;
|
|
42
|
+
};
|
|
43
|
+
readonly Log: {
|
|
44
|
+
/**
|
|
45
|
+
* Set the log level.
|
|
46
|
+
* Acceptable values: 'error' | 'warning' | 'info' | 'verbose'
|
|
47
|
+
* Default value: 'info'
|
|
48
|
+
*
|
|
49
|
+
* Set this to 'verbose' to get browser logs and other IO.
|
|
50
|
+
*/
|
|
51
|
+
readonly setLevel: (newLogLevel: 'verbose' | 'info' | 'warn' | 'error') => void;
|
|
52
|
+
};
|
|
53
|
+
readonly Puppeteer: {
|
|
54
|
+
/**
|
|
55
|
+
* Specify executable path for the browser to use.
|
|
56
|
+
* Default: null, which will make Remotion find or download a version of said browser.
|
|
57
|
+
*/
|
|
58
|
+
readonly setBrowserExecutable: (newBrowserExecutablePath: BrowserExecutable) => void;
|
|
59
|
+
/**
|
|
60
|
+
* Set how many milliseconds a frame may take to render before it times out.
|
|
61
|
+
* Default: `30000`
|
|
62
|
+
*/
|
|
63
|
+
readonly setTimeoutInMilliseconds: (newPuppeteerTimeout: number) => void;
|
|
64
|
+
/**
|
|
65
|
+
* Setting deciding whether to disable CORS and other Chrome security features.
|
|
66
|
+
* Default: false
|
|
67
|
+
*/
|
|
68
|
+
readonly setChromiumDisableWebSecurity: (should: boolean) => void;
|
|
69
|
+
/**
|
|
70
|
+
* Setting whether to ignore any invalid SSL certificates, such as self-signed ones.
|
|
71
|
+
* Default: false
|
|
72
|
+
*/
|
|
73
|
+
readonly setChromiumIgnoreCertificateErrors: (should: boolean) => void;
|
|
74
|
+
/**
|
|
75
|
+
* If false, will open an actual browser during rendering to observe progress.
|
|
76
|
+
* Default: true
|
|
77
|
+
*/
|
|
78
|
+
readonly setChromiumHeadlessMode: (should: boolean) => void;
|
|
79
|
+
/**
|
|
80
|
+
* Set the OpenGL rendering backend for Chrome. Possible values: 'egl', 'angle', 'swiftshader' and 'swangle'.
|
|
81
|
+
* Default: 'swangle' in Lambda, null elsewhere.
|
|
82
|
+
*/
|
|
83
|
+
readonly setChromiumOpenGlRenderer: (renderer: 'swangle' | 'angle' | 'egl' | 'swiftshader') => void;
|
|
84
|
+
};
|
|
85
|
+
readonly Rendering: {
|
|
86
|
+
/**
|
|
87
|
+
* Set a custom location for a .env file.
|
|
88
|
+
* Default: `.env`
|
|
89
|
+
*/
|
|
90
|
+
readonly setDotEnvLocation: (file: string) => void;
|
|
91
|
+
/**
|
|
92
|
+
* Sets how many Puppeteer instances will work on rendering your video in parallel.
|
|
93
|
+
* Default: `null`, meaning half of the threads available on your CPU.
|
|
94
|
+
*/
|
|
95
|
+
readonly setConcurrency: (newConcurrency: Concurrency) => void;
|
|
96
|
+
/**
|
|
97
|
+
* Set the JPEG quality for the frames.
|
|
98
|
+
* Must be between 0 and 100.
|
|
99
|
+
* Must be between 0 and 100.
|
|
100
|
+
* Default: 80
|
|
101
|
+
*/
|
|
102
|
+
readonly setQuality: (q: number | undefined) => void;
|
|
103
|
+
/** Decide in which image format to render. Can be either 'jpeg' or 'png'.
|
|
104
|
+
* PNG is slower, but supports transparency.
|
|
105
|
+
*/
|
|
106
|
+
readonly setImageFormat: (format: 'png' | 'jpeg' | 'none') => void;
|
|
107
|
+
/**
|
|
108
|
+
* Render only a subset of a video.
|
|
109
|
+
* Pass in a tuple [20, 30] to only render frames 20-30 into a video.
|
|
110
|
+
* Pass in a single number `20` to only render a single frame as an image.
|
|
111
|
+
* The frame count starts at 0.
|
|
112
|
+
*/
|
|
113
|
+
readonly setFrameRange: (newFrameRange: FrameRange | null) => void;
|
|
114
|
+
/**
|
|
115
|
+
* Specify local ffmpeg executable.
|
|
116
|
+
* Default: null, which will use ffmpeg available in PATH.
|
|
117
|
+
*/
|
|
118
|
+
readonly setFfmpegExecutable: (ffmpegPath: FfmpegExecutable) => void;
|
|
119
|
+
/**
|
|
120
|
+
* Specify local ffprobe executable.
|
|
121
|
+
* Default: null, which will use ffprobe available in PATH.
|
|
122
|
+
*/
|
|
123
|
+
readonly setFfprobeExecutable: (ffprobePath: FfmpegExecutable) => void;
|
|
124
|
+
/**
|
|
125
|
+
* Scales the output dimensions by a factor.
|
|
126
|
+
* Default: 1.
|
|
127
|
+
*/
|
|
128
|
+
readonly setScale: (newScale: number) => void;
|
|
129
|
+
/**
|
|
130
|
+
* Specify which frames should be picked for rendering a GIF
|
|
131
|
+
* Default: 1, which means every frame
|
|
132
|
+
* https://remotion.dev/docs/render-as-gif
|
|
133
|
+
*/
|
|
134
|
+
readonly setEveryNthFrame: (frame: number) => void;
|
|
135
|
+
/**
|
|
136
|
+
* Specify the number of Loop a GIF should have.
|
|
137
|
+
* Default: null (means GIF will loop infinite)
|
|
138
|
+
*/
|
|
139
|
+
readonly setNumberOfGifLoops: (newLoop: Loop) => void;
|
|
140
|
+
};
|
|
141
|
+
readonly Output: {
|
|
142
|
+
/**
|
|
143
|
+
* Set the output file location string. Default: `out/{composition}.{codec}`
|
|
144
|
+
*/
|
|
145
|
+
readonly setOutputLocation: (newOutputLocation: string) => void;
|
|
146
|
+
/**
|
|
147
|
+
* If the video file already exists, should Remotion overwrite
|
|
148
|
+
* the output? Default: true
|
|
149
|
+
*/
|
|
150
|
+
readonly setOverwriteOutput: (newOverwrite: boolean) => void;
|
|
151
|
+
/**
|
|
152
|
+
* Sets the pixel format in FFMPEG.
|
|
153
|
+
* See https://trac.ffmpeg.org/wiki/Chroma%20Subsampling for an explanation.
|
|
154
|
+
* You can override this using the `--pixel-format` Cli flag.
|
|
155
|
+
*/
|
|
156
|
+
readonly setPixelFormat: (format: 'yuv420p' | 'yuva420p' | 'yuv422p' | 'yuv444p' | 'yuv420p10le' | 'yuv422p10le' | 'yuv444p10le' | 'yuva444p10le') => void;
|
|
157
|
+
/**
|
|
158
|
+
* @deprecated Use setCodec() and setImageSequence() instead.
|
|
159
|
+
* Specify what kind of output you, either `mp4` or `png-sequence`.
|
|
160
|
+
*/
|
|
161
|
+
readonly setOutputFormat: (newLegacyFormat: 'mp4' | 'png-sequence') => void;
|
|
162
|
+
/**
|
|
163
|
+
* Specify the codec for stitching the frames into a video.
|
|
164
|
+
* Can be `h264` (default), `h265`, `vp8` or `vp9`
|
|
165
|
+
*/
|
|
166
|
+
readonly setCodec: (newCodec: CodecOrUndefined) => void;
|
|
167
|
+
/**
|
|
168
|
+
* Set the Constant Rate Factor to pass to FFMPEG.
|
|
169
|
+
* Lower values mean better quality, but be aware that the ranges of
|
|
170
|
+
* possible values greatly differs between codecs.
|
|
171
|
+
*/
|
|
172
|
+
readonly setCrf: (newCrf: Crf) => void;
|
|
173
|
+
/**
|
|
174
|
+
* Set to true if don't want a video but an image sequence as the output.
|
|
175
|
+
*/
|
|
176
|
+
readonly setImageSequence: (newImageSequence: boolean) => void;
|
|
177
|
+
/**
|
|
178
|
+
* Set the ProRes profile.
|
|
179
|
+
* This method is only valid if the codec has been set to 'prores'.
|
|
180
|
+
* Possible values: 4444-xq, 4444, hq, standard, light, proxy. Default: 'hq'
|
|
181
|
+
* See https://avpres.net/FFmpeg/im_ProRes.html for meaning of possible values.
|
|
182
|
+
*/
|
|
183
|
+
readonly setProResProfile: (profile: '4444-xq' | '4444' | 'hq' | 'standard' | 'light' | 'proxy' | undefined) => void;
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
export type { Concurrency, WebpackConfiguration, WebpackOverrideFn };
|
|
187
|
+
export declare const Config: ConfigType;
|
|
188
|
+
export declare const enableLegacyRemotionConfig: () => void;
|
package/dist/config.js
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* The configuration has moved to @remotion/cli.
|
|
4
|
+
* For the moment the type definitions are going to stay here
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.enableLegacyRemotionConfig = exports.Config = void 0;
|
|
8
|
+
const conf = {};
|
|
9
|
+
let enabled = false;
|
|
10
|
+
exports.Config = new Proxy(conf, {
|
|
11
|
+
get(target, prop, receiver) {
|
|
12
|
+
if (!enabled) {
|
|
13
|
+
throw new Error('To use the Remotion config file, you need to have @remotion/cli installed.\n- Make sure that all versions of Remotion are the same.\n- Make sure that @remotion/cli is installed.\n- Make sure Config is imported from "@remotion/cli", not "remotion".');
|
|
14
|
+
}
|
|
15
|
+
return Reflect.get(target, prop, receiver);
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
const enableLegacyRemotionConfig = () => {
|
|
19
|
+
enabled = true;
|
|
20
|
+
};
|
|
21
|
+
exports.enableLegacyRemotionConfig = enableLegacyRemotionConfig;
|
package/dist/delay-render.js
CHANGED
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.continueRender = exports.delayRender = exports.DELAY_RENDER_CALLSTACK_TOKEN = void 0;
|
|
4
4
|
const get_environment_1 = require("./get-environment");
|
|
5
|
-
const timeout_1 = require("./timeout");
|
|
6
5
|
const truthy_1 = require("./truthy");
|
|
7
6
|
if (typeof window !== 'undefined') {
|
|
8
7
|
window.ready = false;
|
|
@@ -10,6 +9,7 @@ if (typeof window !== 'undefined') {
|
|
|
10
9
|
let handles = [];
|
|
11
10
|
const timeouts = {};
|
|
12
11
|
exports.DELAY_RENDER_CALLSTACK_TOKEN = 'The delayRender was called:';
|
|
12
|
+
const defaultTimeout = 30000;
|
|
13
13
|
/**
|
|
14
14
|
* Call this function to tell Remotion to wait before capturing this frame until data has loaded. Use continueRender() to unblock the render.
|
|
15
15
|
* @param label _optional_ A label to identify the call in case it does time out.
|
|
@@ -17,7 +17,7 @@ exports.DELAY_RENDER_CALLSTACK_TOKEN = 'The delayRender was called:';
|
|
|
17
17
|
* @link https://www.remotion.dev/docs/delay-render
|
|
18
18
|
*/
|
|
19
19
|
const delayRender = (label) => {
|
|
20
|
-
var _a, _b;
|
|
20
|
+
var _a, _b, _c;
|
|
21
21
|
if (typeof label !== 'string' && typeof label !== 'undefined') {
|
|
22
22
|
throw new Error('The label parameter of delayRender() must be a string or undefined, got: ' +
|
|
23
23
|
JSON.stringify(label));
|
|
@@ -27,8 +27,8 @@ const delayRender = (label) => {
|
|
|
27
27
|
const called = (_b = (_a = Error().stack) === null || _a === void 0 ? void 0 : _a.replace(/^Error/g, '')) !== null && _b !== void 0 ? _b : '';
|
|
28
28
|
if ((0, get_environment_1.getRemotionEnvironment)() === 'rendering') {
|
|
29
29
|
const timeoutToUse = typeof window === 'undefined'
|
|
30
|
-
?
|
|
31
|
-
: window.remotion_puppeteerTimeout - 2000;
|
|
30
|
+
? defaultTimeout
|
|
31
|
+
: ((_c = window.remotion_puppeteerTimeout) !== null && _c !== void 0 ? _c : defaultTimeout) - 2000;
|
|
32
32
|
timeouts[handle] = setTimeout(() => {
|
|
33
33
|
const message = [
|
|
34
34
|
`A delayRender()`,
|
package/dist/index.d.ts
CHANGED
|
@@ -35,7 +35,7 @@ export * from './AbsoluteFill';
|
|
|
35
35
|
export * from './audio';
|
|
36
36
|
export * from './Composition';
|
|
37
37
|
export { SmallTCompMetadata, TAsset, TCompMetadata } from './CompositionManager';
|
|
38
|
-
export
|
|
38
|
+
export { Config, ConfigType } from './config';
|
|
39
39
|
export { getInputProps } from './config/input-props';
|
|
40
40
|
export * from './delay-render';
|
|
41
41
|
export * from './easing';
|
package/dist/index.js
CHANGED
|
@@ -14,14 +14,15 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
exports.useCurrentFrame = exports.staticFile = exports.Series = exports.Sequence = exports.registerRoot = exports.Loop = exports.interpolateColors = exports.getInputProps = void 0;
|
|
17
|
+
exports.useCurrentFrame = exports.staticFile = exports.Series = exports.Sequence = exports.registerRoot = exports.Loop = exports.interpolateColors = exports.getInputProps = exports.Config = void 0;
|
|
18
18
|
require("./asset-types");
|
|
19
19
|
const multiple_versions_warning_1 = require("./multiple-versions-warning");
|
|
20
20
|
(0, multiple_versions_warning_1.checkMultipleRemotionVersions)();
|
|
21
21
|
__exportStar(require("./AbsoluteFill"), exports);
|
|
22
22
|
__exportStar(require("./audio"), exports);
|
|
23
23
|
__exportStar(require("./Composition"), exports);
|
|
24
|
-
|
|
24
|
+
var config_1 = require("./config");
|
|
25
|
+
Object.defineProperty(exports, "Config", { enumerable: true, get: function () { return config_1.Config; } });
|
|
25
26
|
var input_props_1 = require("./config/input-props");
|
|
26
27
|
Object.defineProperty(exports, "getInputProps", { enumerable: true, get: function () { return input_props_1.getInputProps; } });
|
|
27
28
|
__exportStar(require("./delay-render"), exports);
|
package/dist/internals.d.ts
CHANGED
|
@@ -1,115 +1,47 @@
|
|
|
1
|
+
import type { Configuration } from 'webpack';
|
|
1
2
|
import type { CompProps } from './Composition';
|
|
2
|
-
import type { CompositionManagerContext,
|
|
3
|
-
import * as AssetCompression from './compress-assets';
|
|
4
|
-
import * as Logging from './config/log';
|
|
5
|
-
import type { WebpackOverrideFn } from './config/override-webpack';
|
|
6
|
-
import type { ProResProfile } from './config/prores-profile';
|
|
3
|
+
import type { CompositionManagerContext, TAsset, TCompMetadata, TComposition, TSequence } from './CompositionManager';
|
|
7
4
|
import * as CSSUtils from './default-css';
|
|
8
5
|
import type { RemotionEnvironment } from './get-environment';
|
|
9
|
-
import * as perf from './perf';
|
|
10
|
-
import type { SetTimelineInOutContextValue, TimelineInOutContextValue } from './timeline-inout-position-state';
|
|
11
6
|
import type { SetTimelineContextValue, TimelineContextValue } from './timeline-position-state';
|
|
7
|
+
import * as TimelinePosition from './timeline-position-state';
|
|
12
8
|
import { truthy } from './truthy';
|
|
13
|
-
import type { OpenGlRenderer } from './validation/validate-opengl-renderer';
|
|
14
9
|
import type { MediaVolumeContextValue, SetMediaVolumeContextValue } from './volume-position-state';
|
|
15
10
|
import { useRemotionContexts } from './wrap-remotion-context';
|
|
16
|
-
declare const Timeline:
|
|
17
|
-
TimelineInOutContext: import("react").Context<TimelineInOutContextValue>;
|
|
18
|
-
SetTimelineInOutContext: import("react").Context<SetTimelineInOutContextValue>;
|
|
19
|
-
useTimelineInOutFramePosition: () => TimelineInOutContextValue;
|
|
20
|
-
useTimelineSetInOutFramePosition: () => SetTimelineInOutContextValue;
|
|
21
|
-
TimelineContext: import("react").Context<TimelineContextValue>;
|
|
22
|
-
SetTimelineContext: import("react").Context<SetTimelineContextValue>;
|
|
23
|
-
useTimelinePosition: () => number;
|
|
24
|
-
useTimelineSetFrame: () => (u: import("react").SetStateAction<number>) => void;
|
|
25
|
-
usePlayingState: () => readonly [boolean, (u: import("react").SetStateAction<boolean>) => void, import("react").MutableRefObject<boolean>];
|
|
26
|
-
};
|
|
11
|
+
declare const Timeline: typeof TimelinePosition;
|
|
27
12
|
export declare const Internals: {
|
|
28
|
-
perf: typeof perf;
|
|
29
13
|
useUnsafeVideoConfig: () => import("./video-config").VideoConfig | null;
|
|
30
|
-
Timeline:
|
|
31
|
-
TimelineInOutContext: import("react").Context<TimelineInOutContextValue>;
|
|
32
|
-
SetTimelineInOutContext: import("react").Context<SetTimelineInOutContextValue>;
|
|
33
|
-
useTimelineInOutFramePosition: () => TimelineInOutContextValue;
|
|
34
|
-
useTimelineSetInOutFramePosition: () => SetTimelineInOutContextValue;
|
|
35
|
-
TimelineContext: import("react").Context<TimelineContextValue>;
|
|
36
|
-
SetTimelineContext: import("react").Context<SetTimelineContextValue>;
|
|
37
|
-
useTimelinePosition: () => number;
|
|
38
|
-
useTimelineSetFrame: () => (u: import("react").SetStateAction<number>) => void;
|
|
39
|
-
usePlayingState: () => readonly [boolean, (u: import("react").SetStateAction<boolean>) => void, import("react").MutableRefObject<boolean>];
|
|
40
|
-
};
|
|
14
|
+
Timeline: typeof TimelinePosition;
|
|
41
15
|
CompositionManager: import("react").Context<CompositionManagerContext>;
|
|
42
16
|
RemotionRoot: import("react").FC<{
|
|
43
17
|
children: import("react").ReactNode;
|
|
44
18
|
}>;
|
|
45
19
|
useVideo: () => TComposition<unknown> | null;
|
|
46
20
|
getRoot: () => import("react").FC<{}> | null;
|
|
47
|
-
getBrowserExecutable: () => import("./config/browser-executable").BrowserExecutable;
|
|
48
|
-
getCustomFfmpegExecutable: () => import("./config/ffmpeg-executable").FfmpegExecutable;
|
|
49
|
-
getCustomFfprobeExecutable: () => import("./config/ffmpeg-executable").FfmpegExecutable;
|
|
50
|
-
getPixelFormat: () => "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le";
|
|
51
|
-
getConcurrency: () => number | null;
|
|
52
|
-
getRange: () => import("./config/frame-range").FrameRange | null;
|
|
53
|
-
getShouldOverwrite: () => boolean;
|
|
54
|
-
getOutputCodecOrUndefined: () => import("./config/codec").CodecOrUndefined;
|
|
55
|
-
getWebpackOverrideFn: () => WebpackOverrideFn;
|
|
56
|
-
getQuality: () => number | undefined;
|
|
57
|
-
getAndValidateEveryNthFrame: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => number;
|
|
58
|
-
getAndValidateNumberOfGifLoops: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => number | null;
|
|
59
|
-
getScale: () => number;
|
|
60
|
-
getShouldOutputImageSequence: (frameRange: import("./config/frame-range").FrameRange | null) => boolean;
|
|
61
|
-
validateSelectedCrfAndCodecCombination: (crf: unknown, codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => void;
|
|
62
|
-
getFinalOutputCodec: ({ codec: inputCodec, fileExtension, emitWarning, }: {
|
|
63
|
-
codec: import("./config/codec").CodecOrUndefined;
|
|
64
|
-
fileExtension: string | null;
|
|
65
|
-
emitWarning: boolean;
|
|
66
|
-
}) => "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
67
21
|
useMediaVolumeState: () => readonly [number, (u: number) => void];
|
|
68
22
|
useMediaMutedState: () => readonly [boolean, (u: import("react").SetStateAction<boolean>) => void];
|
|
69
|
-
DEFAULT_CODEC: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
|
|
70
|
-
DEFAULT_PIXEL_FORMAT: "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le";
|
|
71
|
-
FEATURE_FLAG_FIREFOX_SUPPORT: boolean;
|
|
72
|
-
DEFAULT_WEBPACK_CACHE_ENABLED: boolean;
|
|
73
|
-
getBrowser: () => import("./config/browser").Browser | null;
|
|
74
|
-
DEFAULT_BROWSER: import("./config/browser").Browser;
|
|
75
|
-
getDefaultCrfForCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => number;
|
|
76
|
-
getActualCrf: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => number;
|
|
77
|
-
setFrameRangeFromCli: (newFrameRange: string | number) => void;
|
|
78
|
-
getUserPreferredImageFormat: () => "none" | "png" | "jpeg" | undefined;
|
|
79
|
-
validateSelectedPixelFormatAndImageFormatCombination: (pixelFormat: "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le", imageFormat: "none" | "png" | "jpeg") => "none" | "valid";
|
|
80
|
-
validateSelectedPixelFormatAndCodecCombination: (pixelFormat: "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le", codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => void;
|
|
81
|
-
validateFrameRange: (frameRange: import("./config/frame-range").FrameRange | null) => void;
|
|
82
|
-
validateNonNullImageFormat: (imageFormat: "none" | "png" | "jpeg") => void;
|
|
83
|
-
getWebpackCaching: () => boolean;
|
|
84
23
|
useLazyComponent: <T>(compProps: CompProps<T>) => import("react").ExoticComponent<(import("react").PropsWithoutRef<T> & import("react").RefAttributes<import("react").Component<T, any, any>>) | import("react").PropsWithRef<T>> & {
|
|
85
24
|
readonly _result: import("react").ComponentType<T>;
|
|
86
25
|
};
|
|
87
26
|
truthy: typeof truthy;
|
|
88
|
-
isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | undefined) => boolean;
|
|
89
|
-
Logging: typeof Logging;
|
|
90
27
|
SequenceContext: import("react").Context<import("./Sequence").SequenceContextType | null>;
|
|
91
28
|
useRemotionContexts: typeof useRemotionContexts;
|
|
92
29
|
RemotionContextProvider: (props: import("./wrap-remotion-context").RemotionContextProviderProps) => JSX.Element;
|
|
93
30
|
CSSUtils: typeof CSSUtils;
|
|
94
31
|
setupEnvVariables: () => void;
|
|
95
32
|
ENV_VARIABLES_ENV_NAME: "ENV_VARIABLES";
|
|
96
|
-
getDotEnvLocation: () => string | null;
|
|
97
|
-
getServerPort: () => number | undefined;
|
|
98
33
|
MediaVolumeContext: import("react").Context<MediaVolumeContextValue>;
|
|
99
34
|
SetMediaVolumeContext: import("react").Context<SetMediaVolumeContextValue>;
|
|
100
35
|
validateDurationInFrames: (durationInFrames: number, component: string) => void;
|
|
101
|
-
validateFps: (fps: number, location: string,
|
|
36
|
+
validateFps: (fps: number, location: string, isGif: boolean) => void;
|
|
102
37
|
validateDimension: (amount: number, nameOfProp: string, location: string) => void;
|
|
103
38
|
getRemotionEnvironment: () => RemotionEnvironment;
|
|
104
|
-
getProResProfile: () => "4444-xq" | "4444" | "hq" | "standard" | "light" | "proxy" | undefined;
|
|
105
|
-
setProResProfile: (profile: "4444-xq" | "4444" | "hq" | "standard" | "light" | "proxy" | undefined) => void;
|
|
106
|
-
validateSelectedCodecAndProResCombination: (actualCodec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif", actualProResProfile: "4444-xq" | "4444" | "hq" | "standard" | "light" | "proxy" | undefined) => void;
|
|
107
|
-
getMaxTimelineTracks: () => number;
|
|
108
39
|
SharedAudioContext: import("react").Context<{
|
|
109
|
-
registerAudio: (aud: import("./audio").RemotionAudioProps) => {
|
|
40
|
+
registerAudio: (aud: import("./audio").RemotionAudioProps, audioId: string) => {
|
|
110
41
|
id: number;
|
|
111
42
|
props: import("./audio").RemotionAudioProps;
|
|
112
43
|
el: import("react").RefObject<HTMLAudioElement>;
|
|
44
|
+
audioId: string;
|
|
113
45
|
};
|
|
114
46
|
unregisterAudio: (id: number) => void;
|
|
115
47
|
updateAudio: (id: number, aud: import("./audio").RemotionAudioProps) => void;
|
|
@@ -120,25 +52,8 @@ export declare const Internals: {
|
|
|
120
52
|
numberOfAudioTags: number;
|
|
121
53
|
children: import("react").ReactNode;
|
|
122
54
|
}>;
|
|
123
|
-
validateQuality: (q: number | undefined) => void;
|
|
124
|
-
validateFrame: (frame: number, durationInFrames: number) => void;
|
|
125
|
-
setStillFrame: (frame: number) => void;
|
|
126
|
-
getStillFrame: () => number;
|
|
127
55
|
invalidCompositionErrorMessage: string;
|
|
128
56
|
isCompositionIdValid: (id: string) => RegExpMatchArray | null;
|
|
129
|
-
DEFAULT_OVERWRITE: boolean;
|
|
130
|
-
AssetCompression: typeof AssetCompression;
|
|
131
|
-
defaultOverrideFunction: WebpackOverrideFn;
|
|
132
|
-
DEFAULT_PUPPETEER_TIMEOUT: number;
|
|
133
|
-
setupPuppeteerTimeout: () => void;
|
|
134
|
-
setPuppeteerTimeout: (newPuppeteerTimeout: number) => void;
|
|
135
|
-
getCurrentPuppeteerTimeout: () => number;
|
|
136
|
-
getChromiumDisableWebSecurity: () => boolean;
|
|
137
|
-
getIgnoreCertificateErrors: () => boolean;
|
|
138
|
-
validateOpenGlRenderer: (option: "swangle" | "angle" | "egl" | "swiftshader" | null) => "swangle" | "angle" | "egl" | "swiftshader" | null;
|
|
139
|
-
getChromiumOpenGlRenderer: () => "swangle" | "angle" | "egl" | "swiftshader" | null;
|
|
140
|
-
getChromiumHeadlessMode: () => boolean;
|
|
141
|
-
DEFAULT_OPENGL_RENDERER: "swangle" | "angle" | "egl" | "swiftshader" | null;
|
|
142
57
|
getPreviewDomElement: () => HTMLElement | null;
|
|
143
58
|
compositionsRef: import("react").RefObject<{
|
|
144
59
|
getCompositions: () => TCompMetadata[];
|
|
@@ -152,5 +67,8 @@ export declare const Internals: {
|
|
|
152
67
|
children: import("react").ReactNode;
|
|
153
68
|
}>;
|
|
154
69
|
CanUseRemotionHooks: import("react").Context<boolean>;
|
|
70
|
+
enableLegacyRemotionConfig: () => void;
|
|
155
71
|
};
|
|
156
|
-
|
|
72
|
+
declare type WebpackConfiguration = Configuration;
|
|
73
|
+
declare type WebpackOverrideFn = (currentConfiguration: WebpackConfiguration) => WebpackConfiguration;
|
|
74
|
+
export type { TComposition, Timeline, TCompMetadata, TSequence, WebpackOverrideFn, WebpackConfiguration, TAsset, TimelineContextValue, SetTimelineContextValue, CompProps, CompositionManagerContext, MediaVolumeContextValue, SetMediaVolumeContextValue, RemotionEnvironment, };
|
package/dist/internals.js
CHANGED
|
@@ -24,50 +24,20 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.Internals = void 0;
|
|
27
|
+
const config_1 = require("./config");
|
|
27
28
|
const shared_audio_tags_1 = require("./audio/shared-audio-tags");
|
|
28
29
|
const CanUseRemotionHooks_1 = require("./CanUseRemotionHooks");
|
|
29
30
|
const CompositionManager_1 = require("./CompositionManager");
|
|
30
|
-
const AssetCompression = __importStar(require("./compress-assets"));
|
|
31
|
-
const browser_1 = require("./config/browser");
|
|
32
|
-
const browser_executable_1 = require("./config/browser-executable");
|
|
33
|
-
const chromium_flags_1 = require("./config/chromium-flags");
|
|
34
|
-
const codec_1 = require("./config/codec");
|
|
35
|
-
const concurrency_1 = require("./config/concurrency");
|
|
36
|
-
const crf_1 = require("./config/crf");
|
|
37
|
-
const env_file_1 = require("./config/env-file");
|
|
38
|
-
const every_nth_frame_1 = require("./config/every-nth-frame");
|
|
39
|
-
const ffmpeg_executable_1 = require("./config/ffmpeg-executable");
|
|
40
|
-
const frame_range_1 = require("./config/frame-range");
|
|
41
|
-
const image_format_1 = require("./config/image-format");
|
|
42
|
-
const image_sequence_1 = require("./config/image-sequence");
|
|
43
|
-
const Logging = __importStar(require("./config/log"));
|
|
44
|
-
const max_timeline_tracks_1 = require("./config/max-timeline-tracks");
|
|
45
|
-
const number_of_gif_loops_1 = require("./config/number-of-gif-loops");
|
|
46
|
-
const override_webpack_1 = require("./config/override-webpack");
|
|
47
|
-
const overwrite_1 = require("./config/overwrite");
|
|
48
|
-
const pixel_format_1 = require("./config/pixel-format");
|
|
49
|
-
const preview_server_1 = require("./config/preview-server");
|
|
50
|
-
const prores_profile_1 = require("./config/prores-profile");
|
|
51
|
-
const quality_1 = require("./config/quality");
|
|
52
|
-
const scale_1 = require("./config/scale");
|
|
53
|
-
const still_frame_1 = require("./config/still-frame");
|
|
54
|
-
const timeout_1 = require("./config/timeout");
|
|
55
|
-
const webpack_caching_1 = require("./config/webpack-caching");
|
|
56
31
|
const CSSUtils = __importStar(require("./default-css"));
|
|
57
32
|
const delay_render_1 = require("./delay-render");
|
|
58
|
-
const feature_flags_1 = require("./feature-flags");
|
|
59
33
|
const get_environment_1 = require("./get-environment");
|
|
60
34
|
const get_preview_dom_element_1 = require("./get-preview-dom-element");
|
|
61
|
-
const is_audio_codec_1 = require("./is-audio-codec");
|
|
62
|
-
const perf = __importStar(require("./perf"));
|
|
63
35
|
const portal_node_1 = require("./portal-node");
|
|
64
36
|
const register_root_1 = require("./register-root");
|
|
65
37
|
const RemotionRoot_1 = require("./RemotionRoot");
|
|
66
38
|
const Sequence_1 = require("./Sequence");
|
|
67
39
|
const setup_env_variables_1 = require("./setup-env-variables");
|
|
68
|
-
const TimelineInOutPosition = __importStar(require("./timeline-inout-position-state"));
|
|
69
40
|
const TimelinePosition = __importStar(require("./timeline-position-state"));
|
|
70
|
-
const timeout_2 = require("./timeout");
|
|
71
41
|
const truthy_1 = require("./truthy");
|
|
72
42
|
const use_current_frame_1 = require("./use-current-frame");
|
|
73
43
|
const use_lazy_component_1 = require("./use-lazy-component");
|
|
@@ -77,100 +47,39 @@ const validate_composition_id_1 = require("./validation/validate-composition-id"
|
|
|
77
47
|
const validate_dimensions_1 = require("./validation/validate-dimensions");
|
|
78
48
|
const validate_duration_in_frames_1 = require("./validation/validate-duration-in-frames");
|
|
79
49
|
const validate_fps_1 = require("./validation/validate-fps");
|
|
80
|
-
const validate_frame_1 = require("./validation/validate-frame");
|
|
81
|
-
const validate_image_format_1 = require("./validation/validate-image-format");
|
|
82
50
|
const validate_offthreadvideo_image_format_1 = require("./validation/validate-offthreadvideo-image-format");
|
|
83
|
-
const validate_opengl_renderer_1 = require("./validation/validate-opengl-renderer");
|
|
84
|
-
const validate_quality_1 = require("./validation/validate-quality");
|
|
85
51
|
const volume_position_state_1 = require("./volume-position-state");
|
|
86
52
|
const wrap_remotion_context_1 = require("./wrap-remotion-context");
|
|
87
|
-
const Timeline =
|
|
53
|
+
const Timeline = TimelinePosition;
|
|
88
54
|
// Mark them as Internals so use don't assume this is public
|
|
89
55
|
// API and are less likely to use it
|
|
90
56
|
exports.Internals = {
|
|
91
|
-
perf,
|
|
92
57
|
useUnsafeVideoConfig: use_unsafe_video_config_1.useUnsafeVideoConfig,
|
|
93
58
|
Timeline,
|
|
94
59
|
CompositionManager: CompositionManager_1.CompositionManager,
|
|
95
60
|
RemotionRoot: RemotionRoot_1.RemotionRoot,
|
|
96
61
|
useVideo: use_video_1.useVideo,
|
|
97
62
|
getRoot: register_root_1.getRoot,
|
|
98
|
-
getBrowserExecutable: browser_executable_1.getBrowserExecutable,
|
|
99
|
-
getCustomFfmpegExecutable: ffmpeg_executable_1.getCustomFfmpegExecutable,
|
|
100
|
-
getCustomFfprobeExecutable: ffmpeg_executable_1.getCustomFfprobeExecutable,
|
|
101
|
-
getPixelFormat: pixel_format_1.getPixelFormat,
|
|
102
|
-
getConcurrency: concurrency_1.getConcurrency,
|
|
103
|
-
getRange: frame_range_1.getRange,
|
|
104
|
-
getShouldOverwrite: overwrite_1.getShouldOverwrite,
|
|
105
|
-
getOutputCodecOrUndefined: codec_1.getOutputCodecOrUndefined,
|
|
106
|
-
getWebpackOverrideFn: override_webpack_1.getWebpackOverrideFn,
|
|
107
|
-
getQuality: quality_1.getQuality,
|
|
108
|
-
getAndValidateEveryNthFrame: every_nth_frame_1.getAndValidateEveryNthFrame,
|
|
109
|
-
getAndValidateNumberOfGifLoops: number_of_gif_loops_1.getAndValidateNumberOfGifLoops,
|
|
110
|
-
getScale: scale_1.getScale,
|
|
111
|
-
getShouldOutputImageSequence: image_sequence_1.getShouldOutputImageSequence,
|
|
112
|
-
validateSelectedCrfAndCodecCombination: crf_1.validateSelectedCrfAndCodecCombination,
|
|
113
|
-
getFinalOutputCodec: codec_1.getFinalOutputCodec,
|
|
114
63
|
useMediaVolumeState: volume_position_state_1.useMediaVolumeState,
|
|
115
64
|
useMediaMutedState: volume_position_state_1.useMediaMutedState,
|
|
116
|
-
DEFAULT_CODEC: codec_1.DEFAULT_CODEC,
|
|
117
|
-
DEFAULT_PIXEL_FORMAT: pixel_format_1.DEFAULT_PIXEL_FORMAT,
|
|
118
|
-
FEATURE_FLAG_FIREFOX_SUPPORT: feature_flags_1.FEATURE_FLAG_FIREFOX_SUPPORT,
|
|
119
|
-
DEFAULT_WEBPACK_CACHE_ENABLED: webpack_caching_1.DEFAULT_WEBPACK_CACHE_ENABLED,
|
|
120
|
-
getBrowser: browser_1.getBrowser,
|
|
121
|
-
DEFAULT_BROWSER: browser_1.DEFAULT_BROWSER,
|
|
122
|
-
getDefaultCrfForCodec: crf_1.getDefaultCrfForCodec,
|
|
123
|
-
getActualCrf: crf_1.getActualCrf,
|
|
124
|
-
setFrameRangeFromCli: frame_range_1.setFrameRangeFromCli,
|
|
125
|
-
getUserPreferredImageFormat: image_format_1.getUserPreferredImageFormat,
|
|
126
|
-
validateSelectedPixelFormatAndImageFormatCombination: image_format_1.validateSelectedPixelFormatAndImageFormatCombination,
|
|
127
|
-
validateSelectedPixelFormatAndCodecCombination: pixel_format_1.validateSelectedPixelFormatAndCodecCombination,
|
|
128
|
-
validateFrameRange: frame_range_1.validateFrameRange,
|
|
129
|
-
validateNonNullImageFormat: validate_image_format_1.validateNonNullImageFormat,
|
|
130
|
-
getWebpackCaching: webpack_caching_1.getWebpackCaching,
|
|
131
65
|
useLazyComponent: use_lazy_component_1.useLazyComponent,
|
|
132
66
|
truthy: truthy_1.truthy,
|
|
133
|
-
isAudioCodec: is_audio_codec_1.isAudioCodec,
|
|
134
|
-
Logging,
|
|
135
67
|
SequenceContext: Sequence_1.SequenceContext,
|
|
136
68
|
useRemotionContexts: wrap_remotion_context_1.useRemotionContexts,
|
|
137
69
|
RemotionContextProvider: wrap_remotion_context_1.RemotionContextProvider,
|
|
138
70
|
CSSUtils,
|
|
139
71
|
setupEnvVariables: setup_env_variables_1.setupEnvVariables,
|
|
140
72
|
ENV_VARIABLES_ENV_NAME: setup_env_variables_1.ENV_VARIABLES_ENV_NAME,
|
|
141
|
-
getDotEnvLocation: env_file_1.getDotEnvLocation,
|
|
142
|
-
getServerPort: preview_server_1.getServerPort,
|
|
143
73
|
MediaVolumeContext: volume_position_state_1.MediaVolumeContext,
|
|
144
74
|
SetMediaVolumeContext: volume_position_state_1.SetMediaVolumeContext,
|
|
145
75
|
validateDurationInFrames: validate_duration_in_frames_1.validateDurationInFrames,
|
|
146
76
|
validateFps: validate_fps_1.validateFps,
|
|
147
77
|
validateDimension: validate_dimensions_1.validateDimension,
|
|
148
78
|
getRemotionEnvironment: get_environment_1.getRemotionEnvironment,
|
|
149
|
-
getProResProfile: prores_profile_1.getProResProfile,
|
|
150
|
-
setProResProfile: prores_profile_1.setProResProfile,
|
|
151
|
-
validateSelectedCodecAndProResCombination: prores_profile_1.validateSelectedCodecAndProResCombination,
|
|
152
|
-
getMaxTimelineTracks: max_timeline_tracks_1.getMaxTimelineTracks,
|
|
153
79
|
SharedAudioContext: shared_audio_tags_1.SharedAudioContext,
|
|
154
80
|
SharedAudioContextProvider: shared_audio_tags_1.SharedAudioContextProvider,
|
|
155
|
-
validateQuality: validate_quality_1.validateQuality,
|
|
156
|
-
validateFrame: validate_frame_1.validateFrame,
|
|
157
|
-
setStillFrame: still_frame_1.setStillFrame,
|
|
158
|
-
getStillFrame: still_frame_1.getStillFrame,
|
|
159
81
|
invalidCompositionErrorMessage: validate_composition_id_1.invalidCompositionErrorMessage,
|
|
160
82
|
isCompositionIdValid: validate_composition_id_1.isCompositionIdValid,
|
|
161
|
-
DEFAULT_OVERWRITE: overwrite_1.DEFAULT_OVERWRITE,
|
|
162
|
-
AssetCompression,
|
|
163
|
-
defaultOverrideFunction: override_webpack_1.defaultOverrideFunction,
|
|
164
|
-
DEFAULT_PUPPETEER_TIMEOUT: timeout_2.DEFAULT_PUPPETEER_TIMEOUT,
|
|
165
|
-
setupPuppeteerTimeout: timeout_2.setupPuppeteerTimeout,
|
|
166
|
-
setPuppeteerTimeout: timeout_1.setPuppeteerTimeout,
|
|
167
|
-
getCurrentPuppeteerTimeout: timeout_1.getCurrentPuppeteerTimeout,
|
|
168
|
-
getChromiumDisableWebSecurity: chromium_flags_1.getChromiumDisableWebSecurity,
|
|
169
|
-
getIgnoreCertificateErrors: chromium_flags_1.getIgnoreCertificateErrors,
|
|
170
|
-
validateOpenGlRenderer: validate_opengl_renderer_1.validateOpenGlRenderer,
|
|
171
|
-
getChromiumOpenGlRenderer: chromium_flags_1.getChromiumOpenGlRenderer,
|
|
172
|
-
getChromiumHeadlessMode: chromium_flags_1.getChromiumHeadlessMode,
|
|
173
|
-
DEFAULT_OPENGL_RENDERER: chromium_flags_1.DEFAULT_OPENGL_RENDERER,
|
|
174
83
|
getPreviewDomElement: get_preview_dom_element_1.getPreviewDomElement,
|
|
175
84
|
compositionsRef: CompositionManager_1.compositionsRef,
|
|
176
85
|
DELAY_RENDER_CALLSTACK_TOKEN: delay_render_1.DELAY_RENDER_CALLSTACK_TOKEN,
|
|
@@ -180,4 +89,5 @@ exports.Internals = {
|
|
|
180
89
|
validateOffthreadVideoImageFormat: validate_offthreadvideo_image_format_1.validateOffthreadVideoImageFormat,
|
|
181
90
|
CanUseRemotionHooksProvider: CanUseRemotionHooks_1.CanUseRemotionHooksProvider,
|
|
182
91
|
CanUseRemotionHooks: CanUseRemotionHooks_1.CanUseRemotionHooks,
|
|
92
|
+
enableLegacyRemotionConfig: config_1.enableLegacyRemotionConfig,
|
|
183
93
|
};
|
|
@@ -22,7 +22,7 @@ function measureSpring({ fps, config = {}, threshold = 0.005, from = 0, to = 1,
|
|
|
22
22
|
if (threshold < 0) {
|
|
23
23
|
throw new TypeError('Threshold is below 0');
|
|
24
24
|
}
|
|
25
|
-
(0, validate_fps_1.validateFps)(fps, 'to the measureSpring() function',
|
|
25
|
+
(0, validate_fps_1.validateFps)(fps, 'to the measureSpring() function', false);
|
|
26
26
|
const range = Math.abs(from - to);
|
|
27
27
|
let frame = 0;
|
|
28
28
|
let finishedFrame = 0;
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const validateFps: (fps: number, location: string, codec: Codec | null) => void;
|
|
1
|
+
export declare const validateFps: (fps: number, location: string, isGif: boolean) => void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.validateFps = void 0;
|
|
4
|
-
const validateFps = (fps, location,
|
|
4
|
+
const validateFps = (fps, location, isGif) => {
|
|
5
5
|
if (typeof fps !== 'number') {
|
|
6
6
|
throw new Error(`"fps" must be a number, but you passed a value of type ${typeof fps} ${location}`);
|
|
7
7
|
}
|
|
@@ -14,8 +14,8 @@ const validateFps = (fps, location, codec) => {
|
|
|
14
14
|
if (fps <= 0) {
|
|
15
15
|
throw new TypeError(`"fps" must be positive, but got ${fps} ${location}`);
|
|
16
16
|
}
|
|
17
|
-
if (
|
|
18
|
-
throw new TypeError(`The FPS for a GIF
|
|
17
|
+
if (isGif && fps > 50) {
|
|
18
|
+
throw new TypeError(`The FPS for a GIF cannot be higher than 50. Use the --skip-n-frames option to lower the FPS: https://remotion.dev/docs/render-as-gif`);
|
|
19
19
|
}
|
|
20
20
|
};
|
|
21
21
|
exports.validateFps = validateFps;
|