@remotion/renderer 4.0.51 → 4.0.52

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.
Files changed (42) hide show
  1. package/dist/assets/convert-assets-to-file-urls.d.ts +4 -1
  2. package/dist/assets/convert-assets-to-file-urls.js +3 -1
  3. package/dist/assets/download-and-map-assets-to-file.d.ts +7 -2
  4. package/dist/assets/download-and-map-assets-to-file.js +6 -2
  5. package/dist/assets/download-file.d.ts +3 -0
  6. package/dist/assets/download-file.js +2 -0
  7. package/dist/browser/BrowserFetcher.d.ts +5 -1
  8. package/dist/browser/BrowserFetcher.js +3 -1
  9. package/dist/client.d.ts +38 -39
  10. package/dist/get-compositions.js +2 -1
  11. package/dist/get-extension-from-codec.d.ts +2 -2
  12. package/dist/get-local-browser-executable.d.ts +6 -1
  13. package/dist/get-local-browser-executable.js +2 -2
  14. package/dist/get-silent-parts.d.ts +1 -1
  15. package/dist/index.d.ts +61 -48
  16. package/dist/index.js +2 -0
  17. package/dist/is-audio-codec.d.ts +1 -1
  18. package/dist/logger.d.ts +1 -1
  19. package/dist/offthread-video-server.js +1 -1
  20. package/dist/open-browser.js +6 -2
  21. package/dist/options/color-space.d.ts +1 -1
  22. package/dist/options/gl.d.ts +1 -2
  23. package/dist/options/index.d.ts +2 -3
  24. package/dist/provide-screenshot.d.ts +0 -1
  25. package/dist/puppeteer-screenshot.d.ts +0 -1
  26. package/dist/render-frames.d.ts +1 -0
  27. package/dist/render-frames.js +10 -3
  28. package/dist/render-media.js +5 -3
  29. package/dist/render-still.js +3 -1
  30. package/dist/screenshot-dom-element.d.ts +0 -1
  31. package/dist/screenshot-task.d.ts +0 -1
  32. package/dist/select-composition.js +2 -1
  33. package/dist/stitch-frames-to-video.d.ts +0 -1
  34. package/dist/stitch-frames-to-video.js +6 -5
  35. package/dist/take-frame-and-compose.d.ts +0 -1
  36. package/dist/test-gpu.d.ts +14 -0
  37. package/dist/test-gpu.js +40 -0
  38. package/dist/types.d.ts +1 -0
  39. package/dist/validate-opengl-renderer.d.ts +4 -0
  40. package/dist/validate-opengl-renderer.js +21 -0
  41. package/dist/validate-output-filename.d.ts +1 -1
  42. package/package.json +9 -9
@@ -1,8 +1,11 @@
1
1
  import type { TRenderAsset } from 'remotion';
2
+ import type { LogLevel } from '../log-level';
2
3
  import type { RenderMediaOnDownload } from './download-and-map-assets-to-file';
3
4
  import type { DownloadMap } from './download-map';
4
- export declare const convertAssetsToFileUrls: ({ assets, onDownload, downloadMap, }: {
5
+ export declare const convertAssetsToFileUrls: ({ assets, onDownload, downloadMap, indent, logLevel, }: {
5
6
  assets: TRenderAsset[][];
6
7
  onDownload: RenderMediaOnDownload;
7
8
  downloadMap: DownloadMap;
9
+ indent: boolean;
10
+ logLevel: LogLevel;
8
11
  }) => Promise<TRenderAsset[][]>;
@@ -9,7 +9,7 @@ const chunk = (input, size) => {
9
9
  : [...arr.slice(0, -1), [...arr.slice(-1)[0], item]];
10
10
  }, []);
11
11
  };
12
- const convertAssetsToFileUrls = async ({ assets, onDownload, downloadMap, }) => {
12
+ const convertAssetsToFileUrls = async ({ assets, onDownload, downloadMap, indent, logLevel, }) => {
13
13
  const chunks = chunk(assets, 1000);
14
14
  const results = [];
15
15
  for (const ch of chunks) {
@@ -19,6 +19,8 @@ const convertAssetsToFileUrls = async ({ assets, onDownload, downloadMap, }) =>
19
19
  renderAsset: a,
20
20
  onDownload,
21
21
  downloadMap,
22
+ indent,
23
+ logLevel,
22
24
  });
23
25
  }));
24
26
  }));
@@ -1,13 +1,16 @@
1
1
  import type { TRenderAsset } from 'remotion';
2
+ import type { LogLevel } from '../log-level';
2
3
  import type { DownloadMap } from './download-map';
3
4
  export type RenderMediaOnDownload = (src: string) => ((progress: {
4
5
  percent: number | null;
5
6
  downloaded: number;
6
7
  totalSize: number | null;
7
8
  }) => void) | undefined | void;
8
- export declare const downloadAsset: ({ src, downloadMap, }: {
9
+ export declare const downloadAsset: ({ src, downloadMap, indent, logLevel, }: {
9
10
  src: string;
10
11
  downloadMap: DownloadMap;
12
+ indent: boolean;
13
+ logLevel: LogLevel;
11
14
  }) => Promise<string>;
12
15
  export declare const markAllAssetsAsDownloaded: (downloadMap: DownloadMap) => void;
13
16
  export declare const getSanitizedFilenameForAssetUrl: ({ src, downloadDir, contentDisposition, contentType, }: {
@@ -16,9 +19,11 @@ export declare const getSanitizedFilenameForAssetUrl: ({ src, downloadDir, conte
16
19
  contentDisposition: string | null;
17
20
  contentType: string | null;
18
21
  }) => string;
19
- export declare const downloadAndMapAssetsToFileUrl: ({ renderAsset, onDownload, downloadMap, }: {
22
+ export declare const downloadAndMapAssetsToFileUrl: ({ renderAsset, onDownload, downloadMap, logLevel, indent, }: {
20
23
  renderAsset: TRenderAsset;
21
24
  onDownload: RenderMediaOnDownload | null;
22
25
  downloadMap: DownloadMap;
26
+ logLevel: LogLevel;
27
+ indent: boolean;
23
28
  }) => Promise<TRenderAsset>;
24
29
  export declare const attachDownloadListenerToEmitter: (downloadMap: DownloadMap, onDownload: RenderMediaOnDownload | null) => () => void;
@@ -115,7 +115,7 @@ function validateBufferEncoding(potentialEncoding, dataUrl) {
115
115
  throw new TypeError(errMessage);
116
116
  }
117
117
  }
118
- const downloadAsset = async ({ src, downloadMap, }) => {
118
+ const downloadAsset = async ({ src, downloadMap, indent, logLevel, }) => {
119
119
  var _a, _b, _c;
120
120
  if ((0, compress_assets_1.isAssetCompressed)(src)) {
121
121
  return src;
@@ -183,6 +183,8 @@ const downloadAsset = async ({ src, downloadMap, }) => {
183
183
  src,
184
184
  contentType,
185
185
  }),
186
+ indent,
187
+ logLevel,
186
188
  });
187
189
  notifyAssetIsDownloaded({ src, downloadMap, downloadDir, to });
188
190
  return to;
@@ -241,11 +243,13 @@ const getSanitizedFilenameForAssetUrl = ({ src, downloadDir, contentDisposition,
241
243
  return node_path_1.default.join(downloadDir, (0, sanitize_filepath_1.sanitizeFilePath)(filename));
242
244
  };
243
245
  exports.getSanitizedFilenameForAssetUrl = getSanitizedFilenameForAssetUrl;
244
- const downloadAndMapAssetsToFileUrl = async ({ renderAsset, onDownload, downloadMap, }) => {
246
+ const downloadAndMapAssetsToFileUrl = async ({ renderAsset, onDownload, downloadMap, logLevel, indent, }) => {
245
247
  const cleanup = (0, exports.attachDownloadListenerToEmitter)(downloadMap, onDownload);
246
248
  const newSrc = await (0, exports.downloadAsset)({
247
249
  src: renderAsset.src,
248
250
  downloadMap,
251
+ indent,
252
+ logLevel,
249
253
  });
250
254
  cleanup();
251
255
  return {
@@ -1,3 +1,4 @@
1
+ import type { LogLevel } from '../log-level';
1
2
  type Response = {
2
3
  sizeInBytes: number;
3
4
  to: string;
@@ -10,6 +11,8 @@ type Options = {
10
11
  downloaded: number;
11
12
  totalSize: number | null;
12
13
  }) => void) | undefined;
14
+ logLevel: LogLevel;
15
+ indent: boolean;
13
16
  };
14
17
  export declare const downloadFile: (options: Options, retries?: number, attempt?: number) => Promise<Response>;
15
18
  export {};
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.downloadFile = void 0;
4
4
  const node_fs_1 = require("node:fs");
5
5
  const ensure_output_directory_1 = require("../ensure-output-directory");
6
+ const logger_1 = require("../logger");
6
7
  const read_file_1 = require("./read-file");
7
8
  const incorrectContentLengthToken = 'Download finished with';
8
9
  const downloadFileWithoutRetries = ({ onProgress, url, to: toFn }) => {
@@ -99,6 +100,7 @@ const downloadFile = async (options, retries = 2, attempt = 1) => {
99
100
  if (retries === 0) {
100
101
  throw err;
101
102
  }
103
+ logger_1.Log.warnAdvanced({ indent: options.indent, logLevel: options.logLevel }, `Downloading ${options.url} failed (will retry): ${message}`);
102
104
  const backoffInSeconds = (attempt + 1) ** 2;
103
105
  await new Promise((resolve) => {
104
106
  setTimeout(() => resolve(), backoffInSeconds * 1000);
@@ -13,12 +13,16 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ import type { LogLevel } from '../log-level';
16
17
  interface BrowserFetcherRevisionInfo {
17
18
  folderPath: string;
18
19
  executablePath: string;
19
20
  url: string;
20
21
  local: boolean;
21
22
  }
22
- export declare const downloadBrowser: () => Promise<BrowserFetcherRevisionInfo | undefined>;
23
+ export declare const downloadBrowser: (options: {
24
+ logLevel: LogLevel;
25
+ indent: boolean;
26
+ }) => Promise<BrowserFetcherRevisionInfo | undefined>;
23
27
  export declare const getRevisionInfo: () => BrowserFetcherRevisionInfo;
24
28
  export {};
@@ -89,7 +89,7 @@ const destination = '.thorium';
89
89
  const getDownloadsFolder = () => {
90
90
  return path.join((0, get_download_destination_1.getDownloadsCacheDir)(), destination);
91
91
  };
92
- const downloadBrowser = async () => {
92
+ const downloadBrowser = async (options) => {
93
93
  const platform = getPlatform();
94
94
  const downloadURL = getThoriumDownloadUrl(platform);
95
95
  const fileName = downloadURL.split('/').pop();
@@ -123,6 +123,8 @@ const downloadBrowser = async () => {
123
123
  logger_1.Log.info(`Downloading Thorium - ${toMegabytes(progress.downloaded)}/${toMegabytes(progress.totalSize)}`);
124
124
  }
125
125
  },
126
+ indent: options.indent,
127
+ logLevel: options.logLevel,
126
128
  });
127
129
  await install({ archivePath, folderPath: outputPath });
128
130
  }
package/dist/client.d.ts CHANGED
@@ -1,11 +1,10 @@
1
- /// <reference types="react" />
2
1
  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;
2
+ 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
3
  validCodecs: readonly ["h264", "h265", "vp8", "vp9", "mp3", "aac", "wav", "prores", "h264-mkv", "gif"];
5
4
  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;
5
+ getDefaultCrfForCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => number;
6
+ getValidCrfRanges: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => [number, number];
7
+ isAudioCodec: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif" | null | undefined) => boolean;
9
8
  proResProfileOptions: readonly ["4444-xq", "4444", "hq", "standard", "light", "proxy"];
10
9
  x264PresetOptions: readonly ["ultrafast", "superfast", "veryfast", "faster", "fast", "medium", "slow", "slower", "veryslow", "placebo"];
11
10
  validPixelFormats: readonly ["yuv420p", "yuva420p", "yuv422p", "yuv444p", "yuv420p10le", "yuv422p10le", "yuv444p10le", "yuva444p10le"];
@@ -26,11 +25,11 @@ export declare const BrowserSafeApis: {
26
25
  h264: {
27
26
  default: import("./file-extensions").FileExtension;
28
27
  forAudioCodec: {
29
- mp3: {
28
+ aac: {
30
29
  possible: import("./file-extensions").FileExtension[];
31
30
  default: import("./file-extensions").FileExtension;
32
31
  };
33
- aac: {
32
+ mp3: {
34
33
  possible: import("./file-extensions").FileExtension[];
35
34
  default: import("./file-extensions").FileExtension;
36
35
  };
@@ -56,11 +55,11 @@ export declare const BrowserSafeApis: {
56
55
  vp8: {
57
56
  default: import("./file-extensions").FileExtension;
58
57
  forAudioCodec: {
59
- "pcm-16": {
58
+ opus: {
60
59
  possible: import("./file-extensions").FileExtension[];
61
60
  default: import("./file-extensions").FileExtension;
62
61
  };
63
- opus: {
62
+ "pcm-16": {
64
63
  possible: import("./file-extensions").FileExtension[];
65
64
  default: import("./file-extensions").FileExtension;
66
65
  };
@@ -69,20 +68,20 @@ export declare const BrowserSafeApis: {
69
68
  vp9: {
70
69
  default: import("./file-extensions").FileExtension;
71
70
  forAudioCodec: {
72
- "pcm-16": {
71
+ opus: {
73
72
  possible: import("./file-extensions").FileExtension[];
74
73
  default: import("./file-extensions").FileExtension;
75
74
  };
76
- opus: {
75
+ "pcm-16": {
77
76
  possible: import("./file-extensions").FileExtension[];
78
77
  default: import("./file-extensions").FileExtension;
79
78
  };
80
79
  };
81
80
  };
82
- mp3: {
81
+ prores: {
83
82
  default: import("./file-extensions").FileExtension;
84
83
  forAudioCodec: {
85
- mp3: {
84
+ aac: {
86
85
  possible: import("./file-extensions").FileExtension[];
87
86
  default: import("./file-extensions").FileExtension;
88
87
  };
@@ -105,22 +104,22 @@ export declare const BrowserSafeApis: {
105
104
  };
106
105
  };
107
106
  };
108
- wav: {
107
+ mp3: {
109
108
  default: import("./file-extensions").FileExtension;
110
109
  forAudioCodec: {
110
+ mp3: {
111
+ possible: import("./file-extensions").FileExtension[];
112
+ default: import("./file-extensions").FileExtension;
113
+ };
111
114
  "pcm-16": {
112
115
  possible: import("./file-extensions").FileExtension[];
113
116
  default: import("./file-extensions").FileExtension;
114
117
  };
115
118
  };
116
119
  };
117
- prores: {
120
+ wav: {
118
121
  default: import("./file-extensions").FileExtension;
119
122
  forAudioCodec: {
120
- aac: {
121
- possible: import("./file-extensions").FileExtension[];
122
- default: import("./file-extensions").FileExtension;
123
- };
124
123
  "pcm-16": {
125
124
  possible: import("./file-extensions").FileExtension[];
126
125
  default: import("./file-extensions").FileExtension;
@@ -147,37 +146,37 @@ export declare const BrowserSafeApis: {
147
146
  };
148
147
  defaultAudioCodecs: {
149
148
  h264: {
150
- compressed: "mp3" | "aac" | "pcm-16" | null;
151
- lossless: "mp3" | "aac" | "pcm-16" | null;
149
+ compressed: "aac" | "mp3" | "pcm-16" | null;
150
+ lossless: "aac" | "mp3" | "pcm-16" | null;
152
151
  };
153
152
  h265: {
154
153
  compressed: "aac" | "pcm-16" | null;
155
154
  lossless: "aac" | "pcm-16" | null;
156
155
  };
157
156
  vp8: {
158
- compressed: "pcm-16" | "opus" | null;
159
- lossless: "pcm-16" | "opus" | null;
157
+ compressed: "opus" | "pcm-16" | null;
158
+ lossless: "opus" | "pcm-16" | null;
160
159
  };
161
160
  vp9: {
162
- compressed: "pcm-16" | "opus" | null;
163
- lossless: "pcm-16" | "opus" | null;
161
+ compressed: "opus" | "pcm-16" | null;
162
+ lossless: "opus" | "pcm-16" | null;
164
163
  };
165
- mp3: {
166
- compressed: "mp3" | "pcm-16" | null;
167
- lossless: "mp3" | "pcm-16" | null;
164
+ prores: {
165
+ compressed: "aac" | "pcm-16" | null;
166
+ lossless: "aac" | "pcm-16" | null;
168
167
  };
169
168
  aac: {
170
169
  compressed: "aac" | "pcm-16" | null;
171
170
  lossless: "aac" | "pcm-16" | null;
172
171
  };
172
+ mp3: {
173
+ compressed: "mp3" | "pcm-16" | null;
174
+ lossless: "mp3" | "pcm-16" | null;
175
+ };
173
176
  wav: {
174
177
  compressed: "pcm-16" | null;
175
178
  lossless: "pcm-16" | null;
176
179
  };
177
- prores: {
178
- compressed: "aac" | "pcm-16" | null;
179
- lossless: "aac" | "pcm-16" | null;
180
- };
181
180
  "h264-mkv": {
182
181
  compressed: "mp3" | "pcm-16" | null;
183
182
  lossless: "mp3" | "pcm-16" | null;
@@ -187,10 +186,10 @@ export declare const BrowserSafeApis: {
187
186
  lossless: null;
188
187
  };
189
188
  };
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, }: {
189
+ defaultCodecsForFileExtension: Record<import("./file-extensions").FileExtension, "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">;
190
+ validateOutputFilename: <T_1 extends "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif">({ codec, audioCodec, extension, preferLossless, }: {
192
191
  codec: T_1;
193
- audioCodec: "mp3" | "aac" | "pcm-16" | "opus" | null;
192
+ audioCodec: "opus" | "aac" | "mp3" | "pcm-16" | null;
194
193
  extension: string;
195
194
  preferLossless: boolean;
196
195
  }) => void;
@@ -281,7 +280,7 @@ export declare const BrowserSafeApis: {
281
280
  description: () => JSX.Element;
282
281
  docLink: string;
283
282
  ssrName: string;
284
- type: "default" | "bt709";
283
+ type: "bt709" | "default";
285
284
  };
286
285
  deleteAfterOption: {
287
286
  name: string;
@@ -311,7 +310,7 @@ export declare const BrowserSafeApis: {
311
310
  cliFlag: string;
312
311
  docLink: string;
313
312
  name: string;
314
- type: "angle" | "swangle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
313
+ type: "swangle" | "angle" | "egl" | "swiftshader" | "vulkan" | "angle-egl";
315
314
  ssrName: string;
316
315
  description: () => JSX.Element;
317
316
  };
@@ -399,6 +398,6 @@ export declare const BrowserSafeApis: {
399
398
  type: number | null;
400
399
  }];
401
400
  };
402
- codecSupportsCrf: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => boolean;
403
- codecSupportsVideoBitrate: (codec: "h264" | "h265" | "vp8" | "vp9" | "mp3" | "aac" | "wav" | "prores" | "h264-mkv" | "gif") => boolean;
401
+ codecSupportsCrf: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => boolean;
402
+ codecSupportsVideoBitrate: (codec: "h264" | "h265" | "vp8" | "vp9" | "prores" | "aac" | "mp3" | "wav" | "h264-mkv" | "gif") => boolean;
404
403
  };
@@ -59,7 +59,7 @@ const innerGetCompositions = async ({ envVariables, serializedInputPropsWithCust
59
59
  });
60
60
  const res = result;
61
61
  return res.map((r) => {
62
- const { width, durationInFrames, fps, height, id } = r;
62
+ const { width, durationInFrames, fps, height, id, defaultCodec } = r;
63
63
  return {
64
64
  id,
65
65
  width,
@@ -68,6 +68,7 @@ const innerGetCompositions = async ({ envVariables, serializedInputPropsWithCust
68
68
  durationInFrames,
69
69
  props: remotion_1.Internals.deserializeJSONWithCustomFields(r.serializedResolvedPropsWithCustomSchema),
70
70
  defaultProps: remotion_1.Internals.deserializeJSONWithCustomFields(r.serializedDefaultPropsWithCustomSchema),
71
+ defaultCodec,
71
72
  };
72
73
  });
73
74
  };
@@ -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>;
@@ -1,3 +1,8 @@
1
1
  import type { BrowserExecutable } from './browser-executable';
2
- export declare const ensureLocalBrowser: (preferredBrowserExecutable: BrowserExecutable) => Promise<void>;
2
+ import type { LogLevel } from './log-level';
3
+ export declare const ensureLocalBrowser: ({ indent, logLevel, preferredBrowserExecutable, }: {
4
+ preferredBrowserExecutable: BrowserExecutable;
5
+ logLevel: LogLevel;
6
+ indent: boolean;
7
+ }) => Promise<void>;
3
8
  export declare const getLocalBrowserExecutable: (preferredBrowserExecutable: BrowserExecutable) => string;
@@ -68,11 +68,11 @@ const getBrowserStatus = (browserExecutablePath) => {
68
68
  }
69
69
  return { type: 'no-browser' };
70
70
  };
71
- const ensureLocalBrowser = async (preferredBrowserExecutable) => {
71
+ const ensureLocalBrowser = async ({ indent, logLevel, preferredBrowserExecutable, }) => {
72
72
  const status = getBrowserStatus(preferredBrowserExecutable);
73
73
  if (status.type === 'no-browser') {
74
74
  logger_1.Log.info('No local browser could be found. Downloading Thorium https://www.remotion.dev/docs/miscellaneous/thorium-browser');
75
- await (0, BrowserFetcher_1.downloadBrowser)();
75
+ await (0, BrowserFetcher_1.downloadBrowser)({ indent, logLevel });
76
76
  }
77
77
  };
78
78
  exports.ensureLocalBrowser = ensureLocalBrowser;
@@ -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>;