@remotion/renderer 4.0.48 → 4.0.49

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/LICENSE.md CHANGED
@@ -7,7 +7,7 @@ Depending on the type of your legal entity, you are granted permission to use Re
7
7
 
8
8
  ## Free license
9
9
 
10
- Copyright © 2023 [Remotion](https://www.remotion.dev/)
10
+ Copyright © 2023 [Remotion](https://www.remotion.dev)
11
11
 
12
12
  ### Eligibility
13
13
 
@@ -36,6 +36,10 @@ Support is provided on a best-we-can-do basis via GitHub Issues and Discord.
36
36
 
37
37
  ## Company license
38
38
 
39
- You are required to obtain a company license to use Remotion if you are not within the group of entities eligible for a free license. This license will enable you to use Remotion for the allowed use cases specified in the free license, and give you access to prioritized support (read the [Support Policy](/docs/support)).
39
+ You are required to obtain a company license to use Remotion if you are not within the group of entities eligible for a free license. This license will enable you to use Remotion for the allowed use cases specified in the free license, and give you access to prioritized support (read the [Support Policy](https://www.remotion.dev/docs/support)).
40
40
 
41
- Visit [remotion.pro](https://www.remotion.pro) for pricing and to buy a license.
41
+ Visit [remotion.pro](https://www.remotion.pro/license) for pricing and to buy a license.
42
+
43
+ ### FAQs
44
+
45
+ Are you not sure whether you need a company license because of an edge case? Here are some [frequently asked questions](https://www.remotion.pro/faq).
package/dist/client.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  /// <reference types="react" />
2
2
  export declare const BrowserSafeApis: {
3
- getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">(codec: T, audioCodec: "mp3" | "aac" | "pcm-16" | "opus" | null) => import("./file-extensions").FileExtension;
3
+ 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;
4
4
  validCodecs: readonly ["h264", "h265", "vp8", "vp9", "mp3", "aac", "wav", "prores", "h264-mkv", "gif"];
5
5
  validAudioCodecs: readonly ["pcm-16", "aac", "mp3", "opus"];
6
- getDefaultCrfForCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => number;
7
- getValidCrfRanges: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => [number, number];
8
- isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | undefined) => boolean;
6
+ getDefaultCrfForCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => number;
7
+ getValidCrfRanges: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => [number, number];
8
+ isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif" | undefined) => boolean;
9
9
  proResProfileOptions: readonly ["4444-xq", "4444", "hq", "standard", "light", "proxy"];
10
10
  x264PresetOptions: readonly ["ultrafast", "superfast", "veryfast", "faster", "fast", "medium", "slow", "slower", "veryslow", "placebo"];
11
11
  validPixelFormats: readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"];
@@ -26,11 +26,11 @@ export declare const BrowserSafeApis: {
26
26
  h264: {
27
27
  default: import("./file-extensions").FileExtension;
28
28
  forAudioCodec: {
29
- mp3: {
29
+ aac: {
30
30
  possible: import("./file-extensions").FileExtension[];
31
31
  default: import("./file-extensions").FileExtension;
32
32
  };
33
- aac: {
33
+ mp3: {
34
34
  possible: import("./file-extensions").FileExtension[];
35
35
  default: import("./file-extensions").FileExtension;
36
36
  };
@@ -56,11 +56,11 @@ export declare const BrowserSafeApis: {
56
56
  vp8: {
57
57
  default: import("./file-extensions").FileExtension;
58
58
  forAudioCodec: {
59
- "pcm-16": {
59
+ opus: {
60
60
  possible: import("./file-extensions").FileExtension[];
61
61
  default: import("./file-extensions").FileExtension;
62
62
  };
63
- opus: {
63
+ "pcm-16": {
64
64
  possible: import("./file-extensions").FileExtension[];
65
65
  default: import("./file-extensions").FileExtension;
66
66
  };
@@ -69,20 +69,20 @@ export declare const BrowserSafeApis: {
69
69
  vp9: {
70
70
  default: import("./file-extensions").FileExtension;
71
71
  forAudioCodec: {
72
- "pcm-16": {
72
+ opus: {
73
73
  possible: import("./file-extensions").FileExtension[];
74
74
  default: import("./file-extensions").FileExtension;
75
75
  };
76
- opus: {
76
+ "pcm-16": {
77
77
  possible: import("./file-extensions").FileExtension[];
78
78
  default: import("./file-extensions").FileExtension;
79
79
  };
80
80
  };
81
81
  };
82
- mp3: {
82
+ prores: {
83
83
  default: import("./file-extensions").FileExtension;
84
84
  forAudioCodec: {
85
- mp3: {
85
+ aac: {
86
86
  possible: import("./file-extensions").FileExtension[];
87
87
  default: import("./file-extensions").FileExtension;
88
88
  };
@@ -105,22 +105,22 @@ export declare const BrowserSafeApis: {
105
105
  };
106
106
  };
107
107
  };
108
- wav: {
108
+ mp3: {
109
109
  default: import("./file-extensions").FileExtension;
110
110
  forAudioCodec: {
111
+ mp3: {
112
+ possible: import("./file-extensions").FileExtension[];
113
+ default: import("./file-extensions").FileExtension;
114
+ };
111
115
  "pcm-16": {
112
116
  possible: import("./file-extensions").FileExtension[];
113
117
  default: import("./file-extensions").FileExtension;
114
118
  };
115
119
  };
116
120
  };
117
- prores: {
121
+ wav: {
118
122
  default: import("./file-extensions").FileExtension;
119
123
  forAudioCodec: {
120
- aac: {
121
- possible: import("./file-extensions").FileExtension[];
122
- default: import("./file-extensions").FileExtension;
123
- };
124
124
  "pcm-16": {
125
125
  possible: import("./file-extensions").FileExtension[];
126
126
  default: import("./file-extensions").FileExtension;
@@ -147,37 +147,37 @@ export declare const BrowserSafeApis: {
147
147
  };
148
148
  defaultAudioCodecs: {
149
149
  h264: {
150
- compressed: "mp3" | "aac" | "pcm-16" | null;
151
- lossless: "mp3" | "aac" | "pcm-16" | null;
150
+ compressed: "aac" | "mp3" | "pcm-16" | null;
151
+ lossless: "aac" | "mp3" | "pcm-16" | null;
152
152
  };
153
153
  h265: {
154
154
  compressed: "aac" | "pcm-16" | null;
155
155
  lossless: "aac" | "pcm-16" | null;
156
156
  };
157
157
  vp8: {
158
- compressed: "pcm-16" | "opus" | null;
159
- lossless: "pcm-16" | "opus" | null;
158
+ compressed: "opus" | "pcm-16" | null;
159
+ lossless: "opus" | "pcm-16" | null;
160
160
  };
161
161
  vp9: {
162
- compressed: "pcm-16" | "opus" | null;
163
- lossless: "pcm-16" | "opus" | null;
162
+ compressed: "opus" | "pcm-16" | null;
163
+ lossless: "opus" | "pcm-16" | null;
164
164
  };
165
- mp3: {
166
- compressed: "mp3" | "pcm-16" | null;
167
- lossless: "mp3" | "pcm-16" | null;
165
+ prores: {
166
+ compressed: "aac" | "pcm-16" | null;
167
+ lossless: "aac" | "pcm-16" | null;
168
168
  };
169
169
  aac: {
170
170
  compressed: "aac" | "pcm-16" | null;
171
171
  lossless: "aac" | "pcm-16" | null;
172
172
  };
173
+ mp3: {
174
+ compressed: "mp3" | "pcm-16" | null;
175
+ lossless: "mp3" | "pcm-16" | null;
176
+ };
173
177
  wav: {
174
178
  compressed: "pcm-16" | null;
175
179
  lossless: "pcm-16" | null;
176
180
  };
177
- prores: {
178
- compressed: "aac" | "pcm-16" | null;
179
- lossless: "aac" | "pcm-16" | null;
180
- };
181
181
  "h264-mkv": {
182
182
  compressed: "mp3" | "pcm-16" | null;
183
183
  lossless: "mp3" | "pcm-16" | null;
@@ -187,10 +187,10 @@ export declare const BrowserSafeApis: {
187
187
  lossless: null;
188
188
  };
189
189
  };
190
- defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">;
191
- validateOutputFilename: <T_1 extends "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
190
+ defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">;
191
+ validateOutputFilename: <T_1 extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
192
192
  codec: T_1;
193
- audioCodec: "mp3" | "aac" | "pcm-16" | "opus" | null;
193
+ audioCodec: "opus" | "aac" | "mp3" | "pcm-16" | null;
194
194
  extension: string;
195
195
  preferLossless: boolean;
196
196
  }) => void;
@@ -281,7 +281,7 @@ export declare const BrowserSafeApis: {
281
281
  description: () => JSX.Element;
282
282
  docLink: string;
283
283
  ssrName: string;
284
- type: "default" | "bt709";
284
+ type: "bt709" | "default";
285
285
  };
286
286
  deleteAfterOption: {
287
287
  name: string;
@@ -391,6 +391,6 @@ export declare const BrowserSafeApis: {
391
391
  type: number | null;
392
392
  }];
393
393
  };
394
- codecSupportsCrf: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => boolean;
395
- codecSupportsVideoBitrate: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => boolean;
394
+ codecSupportsCrf: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => boolean;
395
+ codecSupportsVideoBitrate: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => boolean;
396
396
  };
@@ -36,6 +36,8 @@ export type VideoMetadata = {
36
36
  canPlayInVideoTag: boolean;
37
37
  supportsSeeking: boolean;
38
38
  colorSpace: 'rgb' | 'bt601' | 'bt709' | 'bt2020-ncl' | 'bt2020-cl' | 'fcc' | 'bt470bg' | 'smpte170m' | 'smpte240m' | 'ycgco' | 'smpte2085' | 'chroma-derived-ncl' | 'chroma-derived-cl' | 'ictcp' | 'unknown';
39
+ audioCodec: null | 'opus' | 'aac' | 'mp3' | 'pcm-f16le' | 'pcm-f24le' | 'pcm-f32be' | 'pcm-s16be' | 'pcm-s16le' | 'pcm-f32le' | 'pcm-s32be' | 'pcm-s32le' | 'pcm-s64be' | 'pcm-s64le' | 'pcm-u16be' | 'pcm-u16le' | 'pcm-u24be' | 'pcm-u24le' | 'pcm-u32be' | 'pcm-u32le' | 'pcm-u8' | 'pcm-f64be' | 'pcm-s24be' | 'pcm-s24le' | 'pcm-s8' | 'pcm-s16be-planar' | 'pcm-s8-planar' | 'pcm-s24le-planar' | 'pcm-s32le-planar' | 'unknown';
40
+ audioFileExtension: string | null;
39
41
  };
40
42
  type SilentPart = {
41
43
  startInSeconds: number;
@@ -88,6 +90,10 @@ export type CompositorCommand = {
88
90
  GetVideoMetadata: {
89
91
  src: string;
90
92
  };
93
+ ExtractAudio: {
94
+ input_path: string;
95
+ output_path: string;
96
+ };
91
97
  VideoMetadata: VideoMetadata;
92
98
  };
93
99
  export type CompositorCommandSerialized<T extends keyof CompositorCommand> = {
@@ -0,0 +1,6 @@
1
+ import type { LogLevel } from './log-level';
2
+ export declare const extractAudio: (options: {
3
+ videoSource: string;
4
+ audioOutput: string;
5
+ logLevel?: LogLevel;
6
+ }) => Promise<void>;
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.extractAudio = void 0;
4
+ const compositor_1 = require("./compositor/compositor");
5
+ const extractAudio = async (options) => {
6
+ var _a;
7
+ const compositor = (0, compositor_1.startLongRunningCompositor)({
8
+ maximumFrameCacheItemsInBytes: null,
9
+ logLevel: (_a = options === null || options === void 0 ? void 0 : options.logLevel) !== null && _a !== void 0 ? _a : 'info',
10
+ indent: false,
11
+ });
12
+ await compositor.executeCommand('ExtractAudio', {
13
+ input_path: options.videoSource,
14
+ output_path: options.audioOutput,
15
+ });
16
+ compositor.finishCommands();
17
+ await compositor.waitForDone();
18
+ };
19
+ exports.extractAudio = extractAudio;
@@ -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" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">(codec: T, audioCodec: AudioCodec | null) => FileExtension;
5
- export declare const makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif")[]>;
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/get-port.js CHANGED
@@ -54,7 +54,7 @@ const getDesiredPort = async ({ desiredPort, from, hostsToTry, to, }) => {
54
54
  if (typeof desiredPort !== 'undefined' &&
55
55
  (await (0, exports.testPortAvailableOnMultipleHosts)({
56
56
  port: desiredPort,
57
- hosts: ['0.0.0.0', '127.0.0.1'],
57
+ hosts: ['::', '::1'],
58
58
  })) === 'available') {
59
59
  return { port: desiredPort, didUsePort };
60
60
  }
@@ -3,6 +3,6 @@ import type { LogLevel } from './log-level';
3
3
  export declare const getSilentParts: ({ src, noiseThresholdInDecibels: passedNoiseThresholdInDecibels, minDurationInSeconds: passedMinDuration, logLevel, }: {
4
4
  src: string;
5
5
  minDurationInSeconds?: number | undefined;
6
- logLevel?: "error" | "verbose" | "info" | "warn" | undefined;
6
+ logLevel?: "verbose" | "info" | "warn" | "error" | undefined;
7
7
  noiseThresholdInDecibels?: number | undefined;
8
8
  }) => Promise<GetSilentPartsResponse>;
@@ -1,5 +1,6 @@
1
1
  import type { VideoMetadata } from './compositor/payloads';
2
2
  import type { LogLevel } from './log-level';
3
+ export { VideoMetadata } from './compositor/payloads';
3
4
  export declare const getVideoMetadata: (videoSource: string, options?: {
4
5
  logLevel?: LogLevel;
5
6
  }) => Promise<VideoMetadata>;
package/dist/index.d.ts CHANGED
@@ -14,12 +14,13 @@ export type { HeadlessBrowser } from './browser/Browser';
14
14
  export { Codec, CodecOrUndefined } from './codec';
15
15
  export { Crf } from './crf';
16
16
  export { ErrorWithStackFrame } from './error-handling/handle-javascript-exception';
17
+ export { extractAudio } from './extract-audio';
17
18
  export type { FfmpegOverrideFn } from './ffmpeg-override';
18
19
  export { FileExtension } from './file-extensions';
19
20
  export { FrameRange } from './frame-range';
20
21
  export { getCompositions, GetCompositionsOptions } from './get-compositions';
21
22
  export { getSilentParts } from './get-silent-parts';
22
- export { getVideoMetadata } from './get-video-metadata';
23
+ export { getVideoMetadata, VideoMetadata } from './get-video-metadata';
23
24
  export { ImageFormat, StillImageFormat, validateSelectedPixelFormatAndImageFormatCombination, VideoImageFormat, } from './image-format';
24
25
  export type { LogLevel } from './log-level';
25
26
  export { CancelSignal, makeCancelSignal } from './make-cancel-signal';
@@ -60,10 +61,10 @@ export declare const RenderInternals: {
60
61
  width: number;
61
62
  height: number;
62
63
  scale: number;
63
- codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
64
+ codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif";
64
65
  wantsImageSequence: boolean;
65
66
  }) => void;
66
- getFileExtensionFromCodec: <T extends "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">(codec: T, audioCodec: "mp3" | "aac" | "pcm-16" | "opus" | null) => import("./file-extensions").FileExtension;
67
+ 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;
67
68
  tmpDir: (str: string) => string;
68
69
  deleteDirectory: (directory: string) => void;
69
70
  isServeUrl: (potentialUrl: string) => boolean;
@@ -118,7 +119,7 @@ export declare const RenderInternals: {
118
119
  };
119
120
  registerErrorSymbolicationLock: () => number;
120
121
  unlockErrorSymbolicationLock: (id: number) => void;
121
- canUseParallelEncoding: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => boolean;
122
+ canUseParallelEncoding: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => boolean;
122
123
  mimeContentType: typeof mimeContentType;
123
124
  mimeLookup: typeof mimeLookup;
124
125
  validateConcurrency: ({ setting, value, checkIfValidForCurrentMachine, }: {
@@ -129,14 +130,14 @@ export declare const RenderInternals: {
129
130
  validPixelFormats: readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"];
130
131
  DEFAULT_BROWSER: "chrome";
131
132
  validateFrameRange: (frameRange: import("./frame-range").FrameRange | null) => void;
132
- DEFAULT_OPENGL_RENDERER: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | null;
133
- validateOpenGlRenderer: (option: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | null) => "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | null;
133
+ DEFAULT_OPENGL_RENDERER: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | null;
134
+ validateOpenGlRenderer: (option: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | null) => "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | null;
134
135
  validCodecs: readonly ["h264", "h265", "vp8", "vp9", "mp3", "aac", "wav", "prores", "h264-mkv", "gif"];
135
136
  DEFAULT_PIXEL_FORMAT: "yuv420p" | "yuva420p" | "yuv422p" | "yuv444p" | "yuv420p10le" | "yuv422p10le" | "yuv444p10le" | "yuva444p10le";
136
137
  validateJpegQuality: (q: number | undefined) => void;
137
138
  DEFAULT_TIMEOUT: number;
138
- DEFAULT_CODEC: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
139
- isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif" | undefined) => boolean;
139
+ DEFAULT_CODEC: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif";
140
+ isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif" | undefined) => boolean;
140
141
  logLevels: readonly ["verbose", "info", "warn", "error"];
141
142
  isEqualOrBelowLogLevel: (currentLevel: "verbose" | "info" | "warn" | "error", level: "verbose" | "info" | "warn" | "error") => boolean;
142
143
  isValidLogLevel: (level: string) => boolean;
@@ -153,28 +154,28 @@ export declare const RenderInternals: {
153
154
  output: string;
154
155
  onProgress: (p: number) => void;
155
156
  numberOfFrames: number;
156
- codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
157
+ codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif";
157
158
  fps: number;
158
159
  numberOfGifLoops: number | null;
159
- audioCodec: "mp3" | "aac" | "pcm-16" | "opus" | null;
160
+ audioCodec: "opus" | "aac" | "mp3" | "pcm-16" | null;
160
161
  audioBitrate: string | null;
161
162
  }) => Promise<void>;
162
163
  getMinConcurrency: () => number;
163
164
  getMaxConcurrency: () => number;
164
165
  getDefaultAudioCodec: ({ codec, preferLossless, }: {
165
- codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif";
166
+ codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif";
166
167
  preferLossless: boolean;
167
- }) => "mp3" | "aac" | "pcm-16" | "opus" | null;
168
+ }) => "opus" | "aac" | "mp3" | "pcm-16" | null;
168
169
  validAudioCodecs: readonly ["pcm-16", "aac", "mp3", "opus"];
169
170
  defaultFileExtensionMap: {
170
171
  h264: {
171
172
  default: import("./file-extensions").FileExtension;
172
173
  forAudioCodec: {
173
- mp3: {
174
+ aac: {
174
175
  possible: import("./file-extensions").FileExtension[];
175
176
  default: import("./file-extensions").FileExtension;
176
177
  };
177
- aac: {
178
+ mp3: {
178
179
  possible: import("./file-extensions").FileExtension[];
179
180
  default: import("./file-extensions").FileExtension;
180
181
  };
@@ -200,11 +201,11 @@ export declare const RenderInternals: {
200
201
  vp8: {
201
202
  default: import("./file-extensions").FileExtension;
202
203
  forAudioCodec: {
203
- "pcm-16": {
204
+ opus: {
204
205
  possible: import("./file-extensions").FileExtension[];
205
206
  default: import("./file-extensions").FileExtension;
206
207
  };
207
- opus: {
208
+ "pcm-16": {
208
209
  possible: import("./file-extensions").FileExtension[];
209
210
  default: import("./file-extensions").FileExtension;
210
211
  };
@@ -213,20 +214,20 @@ export declare const RenderInternals: {
213
214
  vp9: {
214
215
  default: import("./file-extensions").FileExtension;
215
216
  forAudioCodec: {
216
- "pcm-16": {
217
+ opus: {
217
218
  possible: import("./file-extensions").FileExtension[];
218
219
  default: import("./file-extensions").FileExtension;
219
220
  };
220
- opus: {
221
+ "pcm-16": {
221
222
  possible: import("./file-extensions").FileExtension[];
222
223
  default: import("./file-extensions").FileExtension;
223
224
  };
224
225
  };
225
226
  };
226
- mp3: {
227
+ prores: {
227
228
  default: import("./file-extensions").FileExtension;
228
229
  forAudioCodec: {
229
- mp3: {
230
+ aac: {
230
231
  possible: import("./file-extensions").FileExtension[];
231
232
  default: import("./file-extensions").FileExtension;
232
233
  };
@@ -249,22 +250,22 @@ export declare const RenderInternals: {
249
250
  };
250
251
  };
251
252
  };
252
- wav: {
253
+ mp3: {
253
254
  default: import("./file-extensions").FileExtension;
254
255
  forAudioCodec: {
256
+ mp3: {
257
+ possible: import("./file-extensions").FileExtension[];
258
+ default: import("./file-extensions").FileExtension;
259
+ };
255
260
  "pcm-16": {
256
261
  possible: import("./file-extensions").FileExtension[];
257
262
  default: import("./file-extensions").FileExtension;
258
263
  };
259
264
  };
260
265
  };
261
- prores: {
266
+ wav: {
262
267
  default: import("./file-extensions").FileExtension;
263
268
  forAudioCodec: {
264
- aac: {
265
- possible: import("./file-extensions").FileExtension[];
266
- default: import("./file-extensions").FileExtension;
267
- };
268
269
  "pcm-16": {
269
270
  possible: import("./file-extensions").FileExtension[];
270
271
  default: import("./file-extensions").FileExtension;
@@ -301,8 +302,8 @@ export declare const RenderInternals: {
301
302
  readonly vp9: readonly ["opus", "pcm-16"];
302
303
  readonly wav: readonly ["pcm-16"];
303
304
  };
304
- makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif")[]>;
305
- defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">;
305
+ makeFileExtensionMap: () => Record<string, ("h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif")[]>;
306
+ defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">;
306
307
  getExecutablePath: (type: "compositor" | "ffmpeg" | "ffprobe" | "ffmpeg-cwd") => string;
307
308
  callFf: (bin: "ffmpeg" | "ffprobe", args: (string | null)[], options?: execa.Options<string> | undefined) => execa.ExecaChildProcess<string>;
308
309
  dynamicLibraryPathOptions: () => {
@@ -319,8 +320,8 @@ export declare const RenderInternals: {
319
320
  };
320
321
  validStillImageFormats: readonly ["png", "jpeg", "pdf", "webp"];
321
322
  validVideoImageFormats: readonly ["png", "jpeg", "none"];
322
- DEFAULT_STILL_IMAGE_FORMAT: "jpeg" | "png" | "webp" | "pdf";
323
- DEFAULT_VIDEO_IMAGE_FORMAT: "jpeg" | "png" | "none";
323
+ DEFAULT_STILL_IMAGE_FORMAT: "png" | "jpeg" | "pdf" | "webp";
324
+ DEFAULT_VIDEO_IMAGE_FORMAT: "none" | "png" | "jpeg";
324
325
  DEFAULT_JPEG_QUALITY: number;
325
326
  chalk: {
326
327
  enabled: () => boolean;
@@ -433,7 +434,7 @@ export declare const RenderInternals: {
433
434
  frame: number;
434
435
  serializedInputPropsWithCustomSchema: string;
435
436
  serializedResolvedPropsWithCustomSchema: string;
436
- imageFormat: "jpeg" | "png" | "webp" | "pdf";
437
+ imageFormat: "png" | "jpeg" | "pdf" | "webp";
437
438
  jpegQuality: number;
438
439
  puppeteerInstance: HeadlessBrowser | null;
439
440
  envVariables: Record<string, string>;
package/dist/index.js CHANGED
@@ -26,7 +26,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
26
26
  return (mod && mod.__esModule) ? mod : { "default": mod };
27
27
  };
28
28
  Object.defineProperty(exports, "__esModule", { value: true });
29
- exports.RenderInternals = exports.validateOutputFilename = exports.stitchFramesToVideo = exports.selectComposition = exports.renderStill = exports.renderMedia = exports.renderFrames = exports.openBrowser = exports.makeCancelSignal = exports.validateSelectedPixelFormatAndImageFormatCombination = exports.getVideoMetadata = exports.getSilentParts = exports.getCompositions = exports.ErrorWithStackFrame = void 0;
29
+ exports.RenderInternals = exports.validateOutputFilename = exports.stitchFramesToVideo = exports.selectComposition = exports.renderStill = exports.renderMedia = exports.renderFrames = exports.openBrowser = exports.makeCancelSignal = exports.validateSelectedPixelFormatAndImageFormatCombination = exports.getVideoMetadata = exports.getSilentParts = exports.getCompositions = exports.extractAudio = exports.ErrorWithStackFrame = void 0;
30
30
  const execa_1 = __importDefault(require("execa"));
31
31
  const download_file_1 = require("./assets/download-file");
32
32
  const audio_codec_1 = require("./audio-codec");
@@ -85,6 +85,8 @@ const validate_videobitrate_1 = require("./validate-videobitrate");
85
85
  const wait_for_symbolication_error_to_be_done_1 = require("./wait-for-symbolication-error-to-be-done");
86
86
  var handle_javascript_exception_1 = require("./error-handling/handle-javascript-exception");
87
87
  Object.defineProperty(exports, "ErrorWithStackFrame", { enumerable: true, get: function () { return handle_javascript_exception_1.ErrorWithStackFrame; } });
88
+ var extract_audio_1 = require("./extract-audio");
89
+ Object.defineProperty(exports, "extractAudio", { enumerable: true, get: function () { return extract_audio_1.extractAudio; } });
88
90
  var get_compositions_2 = require("./get-compositions");
89
91
  Object.defineProperty(exports, "getCompositions", { enumerable: true, get: function () { return get_compositions_2.getCompositions; } });
90
92
  var get_silent_parts_1 = require("./get-silent-parts");
package/dist/logger.d.ts CHANGED
@@ -19,6 +19,6 @@ export declare const Log: {
19
19
  error: (message?: any, ...optionalParams: any[]) => void;
20
20
  errorAdvanced: (options: VerboseLogOptions, message?: any, ...optionalParams: any[]) => void;
21
21
  };
22
- export declare const getLogLevel: () => "error" | "verbose" | "info" | "warn";
22
+ export declare const getLogLevel: () => "verbose" | "info" | "warn" | "error";
23
23
  export declare const setLogLevel: (newLogLevel: LogLevel) => void;
24
24
  export {};
@@ -7,6 +7,6 @@ export declare const colorSpaceOption: {
7
7
  description: () => JSX.Element;
8
8
  docLink: string;
9
9
  ssrName: string;
10
- type: "default" | "bt709";
10
+ type: "bt709" | "default";
11
11
  };
12
12
  export declare const validateColorSpace: (option: unknown) => void;
@@ -46,7 +46,7 @@ const serveStatic = async (path, options) => {
46
46
  let selectedPort = null;
47
47
  const maxTries = 5;
48
48
  // Default Node.js host, but explicity
49
- const host = '0.0.0.0';
49
+ const host = '::';
50
50
  for (let i = 0; i < maxTries; i++) {
51
51
  try {
52
52
  selectedPort = await new Promise((resolve, reject) => {
@@ -55,7 +55,7 @@ const serveStatic = async (path, options) => {
55
55
  desiredPort: (_a = options === null || options === void 0 ? void 0 : options.port) !== null && _a !== void 0 ? _a : undefined,
56
56
  from: 3000,
57
57
  to: 3100,
58
- hostsToTry: ['0.0.0.0', '127.0.0.1'],
58
+ hostsToTry: ['::', '::1'],
59
59
  })
60
60
  .then(({ port, didUsePort }) => {
61
61
  server.listen({ port, host });
@@ -1,5 +1,5 @@
1
1
  import type { AudioCodec } from './audio-codec';
2
- export declare const validateOutputFilename: <T extends "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
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.48",
3
+ "version": "4.0.49",
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.48"
21
+ "remotion": "4.0.49"
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-linux-arm64-gnu": "4.0.48",
44
- "@remotion/compositor-darwin-arm64": "4.0.48",
45
- "@remotion/compositor-darwin-x64": "4.0.48",
46
- "@remotion/compositor-linux-arm64-musl": "4.0.48",
47
- "@remotion/compositor-linux-x64-gnu": "4.0.48",
48
- "@remotion/compositor-linux-x64-musl": "4.0.48",
49
- "@remotion/compositor-win32-x64-msvc": "4.0.48"
43
+ "@remotion/compositor-darwin-arm64": "4.0.49",
44
+ "@remotion/compositor-darwin-x64": "4.0.49",
45
+ "@remotion/compositor-linux-arm64-gnu": "4.0.49",
46
+ "@remotion/compositor-linux-arm64-musl": "4.0.49",
47
+ "@remotion/compositor-linux-x64-gnu": "4.0.49",
48
+ "@remotion/compositor-linux-x64-musl": "4.0.49",
49
+ "@remotion/compositor-win32-x64-msvc": "4.0.49"
50
50
  },
51
51
  "keywords": [
52
52
  "remotion",