@remotion/cloudrun 4.0.27 → 4.0.28
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 +3 -3
- package/dist/api/render-media-on-cloudrun.d.ts +3 -2
- package/dist/api/render-media-on-cloudrun.js +2 -1
- package/dist/functions/helpers/payloads.d.ts +3 -0
- package/dist/functions/helpers/payloads.js +1 -0
- package/dist/functions/render-media-single-thread.js +1 -0
- package/package.json +6 -6
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
|
|
2
|
-
> @remotion/cloudrun@4.0.
|
|
2
|
+
> @remotion/cloudrun@4.0.27 build /Users/jonathanburger/remotion/packages/cloudrun
|
|
3
3
|
> tsc -d && cp src/shared/sa-permissions.json dist/shared/sa-permissions.json && pnpm run buildContainer && pnpm run tarInstaller
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
> @remotion/cloudrun@4.0.
|
|
6
|
+
> @remotion/cloudrun@4.0.27 buildContainer /Users/jonathanburger/remotion/packages/cloudrun
|
|
7
7
|
> ts-node src/admin/bundle-renderLogic.ts
|
|
8
8
|
|
|
9
9
|
distribution bundled.
|
|
10
10
|
|
|
11
|
-
> @remotion/cloudrun@4.0.
|
|
11
|
+
> @remotion/cloudrun@4.0.27 tarInstaller /Users/jonathanburger/remotion/packages/cloudrun
|
|
12
12
|
> ts-node src/admin/bundle-installer.ts
|
|
13
13
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { AudioCodec, ChromiumOptions, FrameRange, LogLevel, PixelFormat, ProResProfile, ToOptions, VideoImageFormat, X264Preset } from '@remotion/renderer';
|
|
1
|
+
import type { AudioCodec, ChromiumOptions, ColorSpace, FrameRange, LogLevel, PixelFormat, ProResProfile, ToOptions, VideoImageFormat, X264Preset } from '@remotion/renderer';
|
|
2
2
|
import type { BrowserSafeApis } from '@remotion/renderer/client';
|
|
3
3
|
import type { CloudRunCrashResponse, RenderMediaOnCloudrunOutput } from '../functions/helpers/payloads';
|
|
4
4
|
import type { GcpRegion } from '../pricing/gcp-regions';
|
|
@@ -38,6 +38,7 @@ export type RenderMediaOnCloudrunInput = {
|
|
|
38
38
|
concurrency?: number | string | null;
|
|
39
39
|
enforceAudioTrack?: boolean;
|
|
40
40
|
preferLossless?: boolean;
|
|
41
|
+
colorSpace?: ColorSpace;
|
|
41
42
|
} & Partial<ToOptions<typeof BrowserSafeApis.optionsMap.renderMediaOnLambda>>;
|
|
42
43
|
/**
|
|
43
44
|
* @description Triggers a render on a GCP Cloud Run service given a composition and a Cloud Run URL.
|
|
@@ -78,4 +79,4 @@ export type RenderMediaOnCloudrunInput = {
|
|
|
78
79
|
* @param params.preferLossless Uses a lossless audio codec, if one is available for the codec. If you set audioCodec, it takes priority over preferLossless.
|
|
79
80
|
* @returns {Promise<RenderMediaOnCloudrunOutput>} See documentation for detailed structure
|
|
80
81
|
*/
|
|
81
|
-
export declare const renderMediaOnCloudrun: ({ cloudRunUrl, serviceName, region, serveUrl, composition, inputProps, codec, forceBucketName, privacy, outName, updateRenderProgress, jpegQuality, audioCodec, audioBitrate, videoBitrate, proResProfile, x264Preset, crf, pixelFormat, imageFormat, scale, everyNthFrame, numberOfGifLoops, frameRange, envVariables, chromiumOptions, muted, forceWidth, forceHeight, logLevel, delayRenderTimeoutInMilliseconds, concurrency, enforceAudioTrack, preferLossless, offthreadVideoCacheSizeInBytes, }: RenderMediaOnCloudrunInput) => Promise<RenderMediaOnCloudrunOutput | CloudRunCrashResponse>;
|
|
82
|
+
export declare const renderMediaOnCloudrun: ({ cloudRunUrl, serviceName, region, serveUrl, composition, inputProps, codec, forceBucketName, privacy, outName, updateRenderProgress, jpegQuality, audioCodec, audioBitrate, videoBitrate, proResProfile, x264Preset, crf, pixelFormat, imageFormat, scale, everyNthFrame, numberOfGifLoops, frameRange, envVariables, chromiumOptions, muted, forceWidth, forceHeight, logLevel, delayRenderTimeoutInMilliseconds, concurrency, enforceAudioTrack, preferLossless, offthreadVideoCacheSizeInBytes, colorSpace, }: RenderMediaOnCloudrunInput) => Promise<RenderMediaOnCloudrunOutput | CloudRunCrashResponse>;
|
|
@@ -10,7 +10,7 @@ const validate_serveurl_1 = require("../shared/validate-serveurl");
|
|
|
10
10
|
const get_or_create_bucket_1 = require("./get-or-create-bucket");
|
|
11
11
|
const get_auth_client_for_url_1 = require("./helpers/get-auth-client-for-url");
|
|
12
12
|
const get_cloudrun_endpoint_1 = require("./helpers/get-cloudrun-endpoint");
|
|
13
|
-
const renderMediaOnCloudrunRaw = async ({ cloudRunUrl, serviceName, region, serveUrl, composition, inputProps, codec, forceBucketName, privacy, outName, updateRenderProgress, jpegQuality, audioCodec, audioBitrate, videoBitrate, proResProfile, x264Preset, crf, pixelFormat, imageFormat, scale, everyNthFrame, numberOfGifLoops, frameRange, envVariables, chromiumOptions, muted, forceWidth, forceHeight, logLevel, delayRenderTimeoutInMilliseconds, concurrency, enforceAudioTrack, preferLossless, offthreadVideoCacheSizeInBytes, }) => {
|
|
13
|
+
const renderMediaOnCloudrunRaw = async ({ cloudRunUrl, serviceName, region, serveUrl, composition, inputProps, codec, forceBucketName, privacy, outName, updateRenderProgress, jpegQuality, audioCodec, audioBitrate, videoBitrate, proResProfile, x264Preset, crf, pixelFormat, imageFormat, scale, everyNthFrame, numberOfGifLoops, frameRange, envVariables, chromiumOptions, muted, forceWidth, forceHeight, logLevel, delayRenderTimeoutInMilliseconds, concurrency, enforceAudioTrack, preferLossless, offthreadVideoCacheSizeInBytes, colorSpace, }) => {
|
|
14
14
|
const actualCodec = (0, validate_gcp_codec_1.validateCloudrunCodec)(codec);
|
|
15
15
|
(0, validate_serveurl_1.validateServeUrl)(serveUrl);
|
|
16
16
|
if (privacy)
|
|
@@ -58,6 +58,7 @@ const renderMediaOnCloudrunRaw = async ({ cloudRunUrl, serviceName, region, serv
|
|
|
58
58
|
enforceAudioTrack: enforceAudioTrack !== null && enforceAudioTrack !== void 0 ? enforceAudioTrack : false,
|
|
59
59
|
preferLossless: preferLossless !== null && preferLossless !== void 0 ? preferLossless : false,
|
|
60
60
|
offthreadVideoCacheSizeInBytes: offthreadVideoCacheSizeInBytes !== null && offthreadVideoCacheSizeInBytes !== void 0 ? offthreadVideoCacheSizeInBytes : null,
|
|
61
|
+
colorSpace: colorSpace !== null && colorSpace !== void 0 ? colorSpace : 'default',
|
|
61
62
|
};
|
|
62
63
|
const client = await (0, get_auth_client_for_url_1.getAuthClientForUrl)(cloudRunEndpoint);
|
|
63
64
|
const postResponse = await client.request({
|
|
@@ -50,6 +50,7 @@ export declare const CloudRunPayload: z.ZodDiscriminatedUnion<"type", [z.ZodObje
|
|
|
50
50
|
enforceAudioTrack: z.ZodBoolean;
|
|
51
51
|
preferLossless: z.ZodBoolean;
|
|
52
52
|
offthreadVideoCacheSizeInBytes: z.ZodNullable<z.ZodNumber>;
|
|
53
|
+
colorSpace: z.ZodEnum<["default", "bt709"]>;
|
|
53
54
|
}, "strip", z.ZodTypeAny, {
|
|
54
55
|
type: "media";
|
|
55
56
|
serveUrl: string;
|
|
@@ -78,6 +79,7 @@ export declare const CloudRunPayload: z.ZodDiscriminatedUnion<"type", [z.ZodObje
|
|
|
78
79
|
enforceAudioTrack: boolean;
|
|
79
80
|
preferLossless: boolean;
|
|
80
81
|
offthreadVideoCacheSizeInBytes: number | null;
|
|
82
|
+
colorSpace: "default" | "bt709";
|
|
81
83
|
forceHeight?: number | null | undefined;
|
|
82
84
|
forceWidth?: number | null | undefined;
|
|
83
85
|
chromiumOptions?: {
|
|
@@ -117,6 +119,7 @@ export declare const CloudRunPayload: z.ZodDiscriminatedUnion<"type", [z.ZodObje
|
|
|
117
119
|
enforceAudioTrack: boolean;
|
|
118
120
|
preferLossless: boolean;
|
|
119
121
|
offthreadVideoCacheSizeInBytes: number | null;
|
|
122
|
+
colorSpace: "default" | "bt709";
|
|
120
123
|
forceHeight?: number | null | undefined;
|
|
121
124
|
forceWidth?: number | null | undefined;
|
|
122
125
|
chromiumOptions?: {
|
|
@@ -53,6 +53,7 @@ exports.CloudRunPayload = zod_1.z.discriminatedUnion('type', [
|
|
|
53
53
|
enforceAudioTrack: zod_1.z.boolean(),
|
|
54
54
|
preferLossless: zod_1.z.boolean(),
|
|
55
55
|
offthreadVideoCacheSizeInBytes: zod_1.z.number().nullable(),
|
|
56
|
+
colorSpace: zod_1.z.enum(client_1.BrowserSafeApis.validColorSpaces),
|
|
56
57
|
}),
|
|
57
58
|
zod_1.z.object({
|
|
58
59
|
type: zod_1.z.literal('still'),
|
|
@@ -81,6 +81,7 @@ const renderMediaSingleThread = async (body, res) => {
|
|
|
81
81
|
puppeteerInstance: undefined,
|
|
82
82
|
server: undefined,
|
|
83
83
|
offthreadVideoCacheSizeInBytes: body.offthreadVideoCacheSizeInBytes,
|
|
84
|
+
colorSpace: body.colorSpace,
|
|
84
85
|
});
|
|
85
86
|
const storage = new storage_1.Storage();
|
|
86
87
|
const publicUpload = body.privacy === 'public' || !body.privacy;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/cloudrun",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.28",
|
|
4
4
|
"description": "GCP Cloud Run alternative to lambda rendering",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"dependencies": {
|
|
@@ -12,10 +12,10 @@
|
|
|
12
12
|
"@google-cloud/logging": "^10.5.0",
|
|
13
13
|
"google-auth-library": "^8.7.0",
|
|
14
14
|
"zod": "^3.21.4",
|
|
15
|
-
"@remotion/bundler": "4.0.
|
|
16
|
-
"@remotion/
|
|
17
|
-
"remotion": "4.0.
|
|
18
|
-
"
|
|
15
|
+
"@remotion/bundler": "4.0.28",
|
|
16
|
+
"@remotion/cli": "4.0.28",
|
|
17
|
+
"@remotion/renderer": "4.0.28",
|
|
18
|
+
"remotion": "4.0.28"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@jonny/eslint-config": "3.0.266",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"prettier-plugin-organize-imports": "^3.2.2",
|
|
27
27
|
"ts-node": "^10.8.0",
|
|
28
28
|
"vitest": "0.24.3",
|
|
29
|
-
"@remotion/compositor-linux-x64-gnu": "4.0.
|
|
29
|
+
"@remotion/compositor-linux-x64-gnu": "4.0.28"
|
|
30
30
|
},
|
|
31
31
|
"exports": {
|
|
32
32
|
"./package.json": "./package.json",
|