@revideo/create 0.4.4 → 0.4.6-alpha.1017
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/examples/README.md +0 -2
- package/examples/avatar-with-background/package-lock.json +97 -36
- package/examples/avatar-with-background/package.json +6 -6
- package/examples/avatar-with-background/src/project.meta +1 -1
- package/examples/avatar-with-background/src/render.ts +4 -26
- package/examples/{google-cloud-run → avatar-with-background}/src/scenes/example.meta +1 -1
- package/examples/avatar-with-background/src/scenes/example.tsx +0 -1
- package/examples/default/package.json +7 -7
- package/examples/default/src/project.meta +1 -1
- package/examples/github-stars-celebration/package.json +7 -7
- package/examples/github-stars-celebration/src/project.meta +2 -5
- package/examples/google-cloud-run-parallelized/render-orchestrator/package.json +3 -3
- package/examples/google-cloud-run-parallelized/render-worker/package.json +7 -7
- package/examples/google-cloud-run-parallelized/render-worker/src/project.meta +1 -1
- package/examples/marketing-templates/marketing-template/package.json +7 -7
- package/examples/marketing-templates/marketing-template/src/project.meta +2 -5
- package/examples/marketing-templates/marketing-template/src/render.ts +4 -6
- package/examples/marketing-templates/multiple-videos-in-one/package.json +7 -7
- package/examples/marketing-templates/multiple-videos-in-one/src/project.meta +2 -5
- package/examples/marketing-templates/multiple-videos-in-one/src/render.ts +4 -6
- package/examples/parallelized-aws-lambda/.dockerignore +1 -0
- package/examples/parallelized-aws-lambda/revideo-project/package.json +7 -7
- package/examples/parallelized-aws-lambda/revideo-project/src/project.meta +2 -5
- package/examples/saas-template/next/package.json +1 -1
- package/examples/saas-template/revideo/package.json +7 -7
- package/examples/stitching-videos/package.json +6 -6
- package/examples/stitching-videos/src/project.meta +2 -5
- package/examples/stitching-videos/src/project.ts +0 -6
- package/examples/stitching-videos/src/render.ts +9 -41
- package/examples/youtube-shorts/package.json +7 -7
- package/examples/youtube-shorts/src/project.meta +2 -5
- package/examples/youtube-shorts/src/render.ts +4 -1
- package/package.json +9 -9
- package/examples/google-cloud-run/Dockerfile +0 -56
- package/examples/google-cloud-run/README.md +0 -35
- package/examples/google-cloud-run/package.json +0 -28
- package/examples/google-cloud-run/src/index.ts +0 -39
- package/examples/google-cloud-run/src/project.meta +0 -31
- package/examples/google-cloud-run/src/project.ts +0 -7
- package/examples/google-cloud-run/src/revideo.d.ts +0 -1
- package/examples/google-cloud-run/src/scenes/example.tsx +0 -30
- package/examples/google-cloud-run/tsconfig.json +0 -9
- package/examples/google-cloud-run/vite.config.ts +0 -9
package/examples/README.md
CHANGED
|
@@ -34,8 +34,6 @@ Below you can find a list of Revideo projects along with a quick summary, focuse
|
|
|
34
34
|
- **Animation for 1,000 Github Stars:** A fun animation celebrating 1,000 Github stars for Revideo - ([project folder](https://github.com/redotvideo/revideo-examples/tree/main/youtube-shorts))
|
|
35
35
|
### Deployment
|
|
36
36
|
|
|
37
|
-
- **Revideo on Google Cloud Run:** This example project shows you how you can deploy a Revideo Project on Google Cloud Run for Rendering - ([project folder](https://github.com/redotvideo/revideo-examples/tree/main/google-cloud-run))
|
|
38
|
-
|
|
39
37
|
- **Parallelized Rendering with Cloud Functions:** This example project also uses Cloud Run, but enables faster rendering by distributing the rendering work across a large number of cloud functions - ([project folder](https://github.com/redotvideo/revideo-examples/tree/main/google-cloud-run-parallelized))
|
|
40
38
|
|
|
41
39
|
- **Parallelized Rendering with AWS Lambda:** This example project shows you how you can do parallelized rendering with AWS Lambda - ([project folder](https://github.com/redotvideo/revideo-examples/tree/main/parallelized-aws-lambda))
|
|
@@ -9,16 +9,16 @@
|
|
|
9
9
|
"version": "0.0.0",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@deepgram/sdk": "^3.3.0",
|
|
12
|
-
"@revideo/2d": "0.
|
|
13
|
-
"@revideo/core": "0.
|
|
14
|
-
"@revideo/ffmpeg": "0.
|
|
15
|
-
"@revideo/renderer": "0.
|
|
16
|
-
"@revideo/vite-plugin": "0.
|
|
12
|
+
"@revideo/2d": "0.4.4",
|
|
13
|
+
"@revideo/core": "0.4.4",
|
|
14
|
+
"@revideo/ffmpeg": "0.4.4",
|
|
15
|
+
"@revideo/renderer": "0.4.4",
|
|
16
|
+
"@revideo/vite-plugin": "0.4.4",
|
|
17
17
|
"dotenv": "^16.4.5",
|
|
18
18
|
"openai": "^4.39.0"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@revideo/ui": "0.
|
|
21
|
+
"@revideo/ui": "0.4.4",
|
|
22
22
|
"typescript": "^5.2.2",
|
|
23
23
|
"vite": "^4.5"
|
|
24
24
|
}
|
|
@@ -794,55 +794,60 @@
|
|
|
794
794
|
}
|
|
795
795
|
},
|
|
796
796
|
"node_modules/@revideo/2d": {
|
|
797
|
-
"version": "0.
|
|
798
|
-
"resolved": "https://registry.npmjs.org/@revideo/2d/-/2d-0.
|
|
799
|
-
"integrity": "sha512-
|
|
797
|
+
"version": "0.4.4",
|
|
798
|
+
"resolved": "https://registry.npmjs.org/@revideo/2d/-/2d-0.4.4.tgz",
|
|
799
|
+
"integrity": "sha512-oXAytJU5qvtzIRPesWyE0OzCu7vEt34NdrRf5w/+rCrnpmZcoEPQpVw2wf0XgKoX8kizDYCj0J3cuRomI71Uaw==",
|
|
800
800
|
"dependencies": {
|
|
801
801
|
"@codemirror/language": "^6.10.1",
|
|
802
802
|
"@lezer/common": "^1.2.1",
|
|
803
803
|
"@lezer/highlight": "^1.2.0",
|
|
804
|
-
"@revideo/core": "0.
|
|
804
|
+
"@revideo/core": "0.4.4",
|
|
805
805
|
"code-fns": "^0.8.2",
|
|
806
|
+
"hls.js": "^1.5.11",
|
|
806
807
|
"mathjax-full": "^3.2.2",
|
|
808
|
+
"mp4box": "^0.5.2",
|
|
807
809
|
"parse-svg-path": "^0.1.2"
|
|
808
810
|
}
|
|
809
811
|
},
|
|
810
812
|
"node_modules/@revideo/core": {
|
|
811
|
-
"version": "0.
|
|
812
|
-
"resolved": "https://registry.npmjs.org/@revideo/core/-/core-0.
|
|
813
|
-
"integrity": "sha512-
|
|
813
|
+
"version": "0.4.4",
|
|
814
|
+
"resolved": "https://registry.npmjs.org/@revideo/core/-/core-0.4.4.tgz",
|
|
815
|
+
"integrity": "sha512-dW8/qBVCH3LyFiiETCeGhqkrHkRHKT7BaOZcWUZdbf3pyk/g6+yJlWcAL79gB4rdnbSDwZdYQoO2TpHeIxLrjg==",
|
|
814
816
|
"dependencies": {
|
|
815
817
|
"@types/chroma-js": "^2.1.4",
|
|
816
|
-
"chroma-js": "^2.4.2"
|
|
818
|
+
"chroma-js": "^2.4.2",
|
|
819
|
+
"mp4-wasm": "^1.0.6"
|
|
817
820
|
}
|
|
818
821
|
},
|
|
819
822
|
"node_modules/@revideo/ffmpeg": {
|
|
820
|
-
"version": "0.
|
|
821
|
-
"resolved": "https://registry.npmjs.org/@revideo/ffmpeg/-/ffmpeg-0.
|
|
822
|
-
"integrity": "sha512-
|
|
823
|
+
"version": "0.4.4",
|
|
824
|
+
"resolved": "https://registry.npmjs.org/@revideo/ffmpeg/-/ffmpeg-0.4.4.tgz",
|
|
825
|
+
"integrity": "sha512-micam2uQGEn9S3KTQkJXeXfIj8Ch8e7NL+hrFCw8UDleCmYTzgRqJrtWHCNjp0F3XWVNi9NkqfBBygxnB9CiRA==",
|
|
823
826
|
"dependencies": {
|
|
824
827
|
"@ffprobe-installer/ffprobe": "^2.0.0",
|
|
825
|
-
"@revideo/core": "0.
|
|
826
|
-
"@revideo/telemetry": "0.
|
|
828
|
+
"@revideo/core": "0.4.4",
|
|
829
|
+
"@revideo/telemetry": "0.4.4",
|
|
827
830
|
"ffmpeg-static": "^5.2.0",
|
|
831
|
+
"ffprobe-static": "^3.1.0",
|
|
828
832
|
"fluent-ffmpeg": "^2.1.2"
|
|
829
833
|
}
|
|
830
834
|
},
|
|
831
835
|
"node_modules/@revideo/renderer": {
|
|
832
|
-
"version": "0.
|
|
833
|
-
"resolved": "https://registry.npmjs.org/@revideo/renderer/-/renderer-0.
|
|
834
|
-
"integrity": "sha512-
|
|
836
|
+
"version": "0.4.4",
|
|
837
|
+
"resolved": "https://registry.npmjs.org/@revideo/renderer/-/renderer-0.4.4.tgz",
|
|
838
|
+
"integrity": "sha512-Bu2utjMMxDtlrWU6xqeBUZol/ADzPbKdK0xpmgcAW2+HeKlODfUCgX04vJ4j/fCYlMkj6ZBwwqM8IIBs1AFgPw==",
|
|
835
839
|
"dependencies": {
|
|
836
840
|
"@ffmpeg-installer/ffmpeg": "^1.1.0",
|
|
837
841
|
"@ffprobe-installer/ffprobe": "^2.0.0",
|
|
842
|
+
"@revideo/ffmpeg": "0.4.4",
|
|
838
843
|
"puppeteer": "^22.6.0",
|
|
839
844
|
"readline": "^1.3.0"
|
|
840
845
|
}
|
|
841
846
|
},
|
|
842
847
|
"node_modules/@revideo/telemetry": {
|
|
843
|
-
"version": "0.
|
|
844
|
-
"resolved": "https://registry.npmjs.org/@revideo/telemetry/-/telemetry-0.
|
|
845
|
-
"integrity": "sha512-
|
|
848
|
+
"version": "0.4.4",
|
|
849
|
+
"resolved": "https://registry.npmjs.org/@revideo/telemetry/-/telemetry-0.4.4.tgz",
|
|
850
|
+
"integrity": "sha512-LY5i8Uu2Wy2+Q/cmuPHmqLxeL9jZVky286/IWV0i8OHy4UyH5VMPQgqZ2EntpnJocSnqMWtWoM6vhcK+oa32/Q==",
|
|
846
851
|
"hasInstallScript": true,
|
|
847
852
|
"dependencies": {
|
|
848
853
|
"posthog-node": "^4.0.0",
|
|
@@ -853,24 +858,25 @@
|
|
|
853
858
|
}
|
|
854
859
|
},
|
|
855
860
|
"node_modules/@revideo/ui": {
|
|
856
|
-
"version": "0.
|
|
857
|
-
"resolved": "https://registry.npmjs.org/@revideo/ui/-/ui-0.
|
|
858
|
-
"integrity": "sha512-
|
|
861
|
+
"version": "0.4.4",
|
|
862
|
+
"resolved": "https://registry.npmjs.org/@revideo/ui/-/ui-0.4.4.tgz",
|
|
863
|
+
"integrity": "sha512-jCvmxXUKBBlrH6dUUjUV3MZ+rPAtFvZdA9BdgOjebJJ79toDWhVcDgNKrBAon8cj+55VB/IPoR6poMj/XolD3A==",
|
|
859
864
|
"dev": true,
|
|
860
865
|
"dependencies": {
|
|
861
866
|
"@preact/signals": "^1.2.1",
|
|
862
|
-
"@revideo/core": "0.
|
|
867
|
+
"@revideo/core": "0.4.4",
|
|
863
868
|
"preact": "^10.19.2"
|
|
864
869
|
}
|
|
865
870
|
},
|
|
866
871
|
"node_modules/@revideo/vite-plugin": {
|
|
867
|
-
"version": "0.
|
|
868
|
-
"resolved": "https://registry.npmjs.org/@revideo/vite-plugin/-/vite-plugin-0.
|
|
869
|
-
"integrity": "sha512-
|
|
872
|
+
"version": "0.4.4",
|
|
873
|
+
"resolved": "https://registry.npmjs.org/@revideo/vite-plugin/-/vite-plugin-0.4.4.tgz",
|
|
874
|
+
"integrity": "sha512-IyhPqLaNBAx5+NSgWK/cd3EpRqgWyXCCp/59r6tTP+DSMomU06pue975YZQr1JaWCe/MqdtsldQIiek9EEVxzg==",
|
|
870
875
|
"dependencies": {
|
|
871
|
-
"@revideo/ffmpeg": "0.
|
|
876
|
+
"@revideo/ffmpeg": "0.4.4",
|
|
872
877
|
"fast-glob": "^3.3.1",
|
|
873
878
|
"follow-redirects": "^1.15.2",
|
|
879
|
+
"formidable": "^3.5.1",
|
|
874
880
|
"mime-types": "^2.1.35",
|
|
875
881
|
"source-map": "^0.6.1"
|
|
876
882
|
},
|
|
@@ -1005,6 +1011,11 @@
|
|
|
1005
1011
|
"resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz",
|
|
1006
1012
|
"integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q=="
|
|
1007
1013
|
},
|
|
1014
|
+
"node_modules/asap": {
|
|
1015
|
+
"version": "2.0.6",
|
|
1016
|
+
"resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz",
|
|
1017
|
+
"integrity": "sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA=="
|
|
1018
|
+
},
|
|
1008
1019
|
"node_modules/ast-types": {
|
|
1009
1020
|
"version": "0.13.4",
|
|
1010
1021
|
"resolved": "https://registry.npmjs.org/ast-types/-/ast-types-0.13.4.tgz",
|
|
@@ -1027,9 +1038,9 @@
|
|
|
1027
1038
|
"integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q=="
|
|
1028
1039
|
},
|
|
1029
1040
|
"node_modules/axios": {
|
|
1030
|
-
"version": "1.
|
|
1031
|
-
"resolved": "https://registry.npmjs.org/axios/-/axios-1.
|
|
1032
|
-
"integrity": "sha512-
|
|
1041
|
+
"version": "1.7.2",
|
|
1042
|
+
"resolved": "https://registry.npmjs.org/axios/-/axios-1.7.2.tgz",
|
|
1043
|
+
"integrity": "sha512-2A8QhOMrbomlDuiLeK9XibIBzuHeRcqqNOHp0Cyp5EoJ1IFDh+XZH3A6BkXtv0K4gFGCI0Y4BM7B1wOEi0Rmgw==",
|
|
1033
1044
|
"dependencies": {
|
|
1034
1045
|
"follow-redirects": "^1.15.6",
|
|
1035
1046
|
"form-data": "^4.0.0",
|
|
@@ -1387,6 +1398,15 @@
|
|
|
1387
1398
|
"resolved": "https://registry.npmjs.org/devtools-protocol/-/devtools-protocol-0.0.1273771.tgz",
|
|
1388
1399
|
"integrity": "sha512-QDbb27xcTVReQQW/GHJsdQqGKwYBE7re7gxehj467kKP2DKuYBUj6i2k5LRiAC66J1yZG/9gsxooz/s9pcm0Og=="
|
|
1389
1400
|
},
|
|
1401
|
+
"node_modules/dezalgo": {
|
|
1402
|
+
"version": "1.0.4",
|
|
1403
|
+
"resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.4.tgz",
|
|
1404
|
+
"integrity": "sha512-rXSP0bf+5n0Qonsb+SVVfNfIsimO4HEtmnIpPHY8Q1UCzKlQrDMfdobr8nJOOsRgWCyMRqeSBQzmWUMq7zvVig==",
|
|
1405
|
+
"dependencies": {
|
|
1406
|
+
"asap": "^2.0.0",
|
|
1407
|
+
"wrappy": "1"
|
|
1408
|
+
}
|
|
1409
|
+
},
|
|
1390
1410
|
"node_modules/dotenv": {
|
|
1391
1411
|
"version": "16.4.5",
|
|
1392
1412
|
"resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.5.tgz",
|
|
@@ -1712,6 +1732,11 @@
|
|
|
1712
1732
|
"node": ">= 6"
|
|
1713
1733
|
}
|
|
1714
1734
|
},
|
|
1735
|
+
"node_modules/ffprobe-static": {
|
|
1736
|
+
"version": "3.1.0",
|
|
1737
|
+
"resolved": "https://registry.npmjs.org/ffprobe-static/-/ffprobe-static-3.1.0.tgz",
|
|
1738
|
+
"integrity": "sha512-Dvpa9uhVMOYivhHKWLGDoa512J751qN1WZAIO+Xw4L/mrUSPxS4DApzSUDbCFE/LUq2+xYnznEahTd63AqBSpA=="
|
|
1739
|
+
},
|
|
1715
1740
|
"node_modules/fill-range": {
|
|
1716
1741
|
"version": "7.0.1",
|
|
1717
1742
|
"resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz",
|
|
@@ -1792,6 +1817,19 @@
|
|
|
1792
1817
|
"node": ">= 14"
|
|
1793
1818
|
}
|
|
1794
1819
|
},
|
|
1820
|
+
"node_modules/formidable": {
|
|
1821
|
+
"version": "3.5.1",
|
|
1822
|
+
"resolved": "https://registry.npmjs.org/formidable/-/formidable-3.5.1.tgz",
|
|
1823
|
+
"integrity": "sha512-WJWKelbRHN41m5dumb0/k8TeAx7Id/y3a+Z7QfhxP/htI9Js5zYaEDtG8uMgG0vM0lOlqnmjE99/kfpOYi/0Og==",
|
|
1824
|
+
"dependencies": {
|
|
1825
|
+
"dezalgo": "^1.0.4",
|
|
1826
|
+
"hexoid": "^1.0.0",
|
|
1827
|
+
"once": "^1.4.0"
|
|
1828
|
+
},
|
|
1829
|
+
"funding": {
|
|
1830
|
+
"url": "https://ko-fi.com/tunnckoCore/commissions"
|
|
1831
|
+
}
|
|
1832
|
+
},
|
|
1795
1833
|
"node_modules/fs-extra": {
|
|
1796
1834
|
"version": "11.2.0",
|
|
1797
1835
|
"resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.2.0.tgz",
|
|
@@ -1878,6 +1916,19 @@
|
|
|
1878
1916
|
"node": ">=4"
|
|
1879
1917
|
}
|
|
1880
1918
|
},
|
|
1919
|
+
"node_modules/hexoid": {
|
|
1920
|
+
"version": "1.0.0",
|
|
1921
|
+
"resolved": "https://registry.npmjs.org/hexoid/-/hexoid-1.0.0.tgz",
|
|
1922
|
+
"integrity": "sha512-QFLV0taWQOZtvIRIAdBChesmogZrtuXvVWsFHZTk2SU+anspqZ2vMnoLg7IE1+Uk16N19APic1BuF8bC8c2m5g==",
|
|
1923
|
+
"engines": {
|
|
1924
|
+
"node": ">=8"
|
|
1925
|
+
}
|
|
1926
|
+
},
|
|
1927
|
+
"node_modules/hls.js": {
|
|
1928
|
+
"version": "1.5.11",
|
|
1929
|
+
"resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.5.11.tgz",
|
|
1930
|
+
"integrity": "sha512-q3We1izi2+qkOO+TvZdHv+dx6aFzdtk3xc1/Qesrvto4thLTT/x/1FK85c5h1qZE4MmMBNgKg+MIW8nxQfxwBw=="
|
|
1931
|
+
},
|
|
1881
1932
|
"node_modules/http-proxy-agent": {
|
|
1882
1933
|
"version": "7.0.2",
|
|
1883
1934
|
"resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz",
|
|
@@ -2148,6 +2199,16 @@
|
|
|
2148
2199
|
"resolved": "https://registry.npmjs.org/mj-context-menu/-/mj-context-menu-0.6.1.tgz",
|
|
2149
2200
|
"integrity": "sha512-7NO5s6n10TIV96d4g2uDpG7ZDpIhMh0QNfGdJw/W47JswFcosz457wqz/b5sAKvl12sxINGFCn80NZHKwxQEXA=="
|
|
2150
2201
|
},
|
|
2202
|
+
"node_modules/mp4-wasm": {
|
|
2203
|
+
"version": "1.0.6",
|
|
2204
|
+
"resolved": "https://registry.npmjs.org/mp4-wasm/-/mp4-wasm-1.0.6.tgz",
|
|
2205
|
+
"integrity": "sha512-iXVP+YK/aLDkdl9Iy+QQgAYL5/dxEDA1+uYEBW6heEYJkg6gkTGgD2Sz4hciryqr2kJoDCRGfPmgH0A1WHMULQ=="
|
|
2206
|
+
},
|
|
2207
|
+
"node_modules/mp4box": {
|
|
2208
|
+
"version": "0.5.2",
|
|
2209
|
+
"resolved": "https://registry.npmjs.org/mp4box/-/mp4box-0.5.2.tgz",
|
|
2210
|
+
"integrity": "sha512-zRmGlvxy+YdW3Dmt+TR4xPHynbxwXtAQDTN/Fo9N3LMxaUlB2C5KmZpzYyGKy4c7k4Jf3RCR0A2pm9SZELOLXw=="
|
|
2211
|
+
},
|
|
2151
2212
|
"node_modules/ms": {
|
|
2152
2213
|
"version": "2.1.2",
|
|
2153
2214
|
"resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz",
|
|
@@ -10,16 +10,16 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@deepgram/sdk": "^3.3.0",
|
|
13
|
-
"@revideo/2d": "0.
|
|
14
|
-
"@revideo/core": "0.
|
|
15
|
-
"@revideo/ffmpeg": "0.
|
|
16
|
-
"@revideo/renderer": "0.
|
|
17
|
-
"@revideo/vite-plugin": "0.
|
|
13
|
+
"@revideo/2d": "0.4.5",
|
|
14
|
+
"@revideo/core": "0.4.5",
|
|
15
|
+
"@revideo/ffmpeg": "0.4.5",
|
|
16
|
+
"@revideo/renderer": "0.4.5",
|
|
17
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
18
18
|
"dotenv": "^16.4.5",
|
|
19
19
|
"openai": "^4.39.0"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@revideo/ui": "0.
|
|
22
|
+
"@revideo/ui": "0.4.5",
|
|
23
23
|
"typescript": "^5.2.2",
|
|
24
24
|
"vite": "^4.5"
|
|
25
25
|
}
|
|
@@ -1,34 +1,12 @@
|
|
|
1
1
|
import {renderVideo} from '@revideo/renderer';
|
|
2
2
|
|
|
3
|
-
const progressTracker = new Map<number, number>();
|
|
4
|
-
|
|
5
|
-
function trackProgress(id: number, progress: number) {
|
|
6
|
-
progressTracker.set(id, progress);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
function printProgress() {
|
|
10
|
-
let line = '';
|
|
11
|
-
for (const [key, value] of progressTracker.entries()) {
|
|
12
|
-
line += `Worker ${key}: ${(value * 100).toFixed(0)}% `;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
if (line === '') {
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
console.log(line);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
3
|
async function render() {
|
|
23
4
|
console.log('Rendering video...');
|
|
24
5
|
|
|
25
|
-
const
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const file = await renderVideo('./vite.config.ts', {}, trackProgress);
|
|
30
|
-
|
|
31
|
-
clearInterval(interval);
|
|
6
|
+
const file = await renderVideo({
|
|
7
|
+
projectFile: './src/project.ts',
|
|
8
|
+
settings: { logProgress: true }
|
|
9
|
+
});
|
|
32
10
|
|
|
33
11
|
console.log(`Rendered video to ${file}`);
|
|
34
12
|
}
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "^0.4.
|
|
13
|
-
"@revideo/2d": "^0.4.
|
|
14
|
-
"@revideo/renderer": "^0.4.
|
|
15
|
-
"@revideo/vite-plugin": "^0.4.
|
|
16
|
-
"@revideo/ffmpeg": "^0.4.
|
|
12
|
+
"@revideo/core": "^0.4.5",
|
|
13
|
+
"@revideo/2d": "^0.4.5",
|
|
14
|
+
"@revideo/renderer": "^0.4.5",
|
|
15
|
+
"@revideo/vite-plugin": "^0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "^0.4.5"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "^0.4.
|
|
20
|
-
"@revideo/cli": "^0.4.
|
|
19
|
+
"@revideo/ui": "^0.4.5",
|
|
20
|
+
"@revideo/cli": "^0.4.5",
|
|
21
21
|
"typescript": "^5.2.2",
|
|
22
22
|
"vite": "^4.5"
|
|
23
23
|
}
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "^0.4.
|
|
13
|
-
"@revideo/2d": "^0.4.
|
|
14
|
-
"@revideo/renderer": "^0.4.
|
|
15
|
-
"@revideo/vite-plugin": "^0.4.
|
|
16
|
-
"@revideo/ffmpeg": "^0.4.
|
|
12
|
+
"@revideo/core": "^0.4.5",
|
|
13
|
+
"@revideo/2d": "^0.4.5",
|
|
14
|
+
"@revideo/renderer": "^0.4.5",
|
|
15
|
+
"@revideo/vite-plugin": "^0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "^0.4.5"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "^0.4.
|
|
20
|
-
"@revideo/cli": "^0.4.
|
|
19
|
+
"@revideo/ui": "^0.4.5",
|
|
20
|
+
"@revideo/cli": "^0.4.5",
|
|
21
21
|
"typescript": "^5.2.2",
|
|
22
22
|
"vite": "^4.5"
|
|
23
23
|
}
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
},
|
|
8
8
|
"dependencies": {
|
|
9
9
|
"@google-cloud/storage": "^7.11.0",
|
|
10
|
-
"@revideo/2d": "0.4.
|
|
11
|
-
"@revideo/core": "0.4.
|
|
12
|
-
"@revideo/ffmpeg": "0.4.
|
|
10
|
+
"@revideo/2d": "0.4.5",
|
|
11
|
+
"@revideo/core": "0.4.5",
|
|
12
|
+
"@revideo/ffmpeg": "0.4.5",
|
|
13
13
|
"express": "^4.19.2",
|
|
14
14
|
"uuid": "^9.0.1"
|
|
15
15
|
},
|
|
@@ -12,13 +12,13 @@
|
|
|
12
12
|
"@ffprobe-installer/ffprobe": "^2.1.2",
|
|
13
13
|
"@google-cloud/functions-framework": "^3.4.0",
|
|
14
14
|
"@google-cloud/storage": "^7.11.0",
|
|
15
|
-
"@revideo/2d": "0.4.
|
|
16
|
-
"@revideo/cli": "^0.4.
|
|
17
|
-
"@revideo/core": "0.4.
|
|
18
|
-
"@revideo/ffmpeg": "0.4.
|
|
19
|
-
"@revideo/renderer": "0.4.
|
|
20
|
-
"@revideo/ui": "0.4.
|
|
21
|
-
"@revideo/vite-plugin": "0.4.
|
|
15
|
+
"@revideo/2d": "0.4.5",
|
|
16
|
+
"@revideo/cli": "^0.4.5",
|
|
17
|
+
"@revideo/core": "0.4.5",
|
|
18
|
+
"@revideo/ffmpeg": "0.4.5",
|
|
19
|
+
"@revideo/renderer": "0.4.5",
|
|
20
|
+
"@revideo/ui": "0.4.5",
|
|
21
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
22
22
|
"@types/express": "^4.17.21",
|
|
23
23
|
"@types/uuid": "^9.0.8",
|
|
24
24
|
"express": "^4.19.2",
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "0.
|
|
13
|
-
"@revideo/2d": "0.
|
|
14
|
-
"@revideo/renderer": "0.
|
|
15
|
-
"@revideo/vite-plugin": "0.
|
|
16
|
-
"@revideo/ffmpeg": "0.
|
|
12
|
+
"@revideo/core": "0.4.5",
|
|
13
|
+
"@revideo/2d": "0.4.5",
|
|
14
|
+
"@revideo/renderer": "0.4.5",
|
|
15
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "0.4.5"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "0.
|
|
20
|
-
"@revideo/cli": "^0.
|
|
19
|
+
"@revideo/ui": "0.4.5",
|
|
20
|
+
"@revideo/cli": "^0.4.5",
|
|
21
21
|
"typescript": "^5.2.2",
|
|
22
22
|
"vite": "^4.5"
|
|
23
23
|
}
|
|
@@ -4,12 +4,10 @@ async function render() {
|
|
|
4
4
|
console.log('Rendering video...');
|
|
5
5
|
|
|
6
6
|
// This is the main function that renders the video
|
|
7
|
-
const file = await renderVideo(
|
|
8
|
-
|
|
9
|
-
{
|
|
10
|
-
|
|
11
|
-
{logProgress: true},
|
|
12
|
-
);
|
|
7
|
+
const file = await renderVideo({
|
|
8
|
+
projectFile: "./src/project.ts",
|
|
9
|
+
settings: {logProgress: true},
|
|
10
|
+
});
|
|
13
11
|
|
|
14
12
|
console.log(`Rendered video to ${file}`);
|
|
15
13
|
}
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "0.
|
|
13
|
-
"@revideo/2d": "0.
|
|
14
|
-
"@revideo/renderer": "0.
|
|
15
|
-
"@revideo/vite-plugin": "0.
|
|
16
|
-
"@revideo/ffmpeg": "0.
|
|
12
|
+
"@revideo/core": "0.4.5",
|
|
13
|
+
"@revideo/2d": "0.4.5",
|
|
14
|
+
"@revideo/renderer": "0.4.5",
|
|
15
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "0.4.5"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "0.
|
|
20
|
-
"@revideo/cli": "^0.
|
|
19
|
+
"@revideo/ui": "0.4.5",
|
|
20
|
+
"@revideo/cli": "^0.4.5",
|
|
21
21
|
"typescript": "^5.2.2",
|
|
22
22
|
"vite": "^4.5"
|
|
23
23
|
}
|
|
@@ -4,12 +4,10 @@ async function render() {
|
|
|
4
4
|
console.log('Rendering video...');
|
|
5
5
|
|
|
6
6
|
// This is the main function that renders the video
|
|
7
|
-
const file = await renderVideo(
|
|
8
|
-
'./
|
|
9
|
-
{
|
|
10
|
-
|
|
11
|
-
{logProgress: true},
|
|
12
|
-
);
|
|
7
|
+
const file = await renderVideo({
|
|
8
|
+
projectFile: './src/project.ts',
|
|
9
|
+
settings: {logProgress: true},
|
|
10
|
+
});
|
|
13
11
|
|
|
14
12
|
console.log(`Rendered video to ${file}`);
|
|
15
13
|
}
|
|
@@ -9,19 +9,19 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/2d": "0.4.
|
|
13
|
-
"@revideo/core": "0.4.
|
|
14
|
-
"@revideo/ffmpeg": "0.4.
|
|
15
|
-
"@revideo/renderer": "0.4.
|
|
16
|
-
"@revideo/vite-plugin": "0.4.
|
|
12
|
+
"@revideo/2d": "0.4.5",
|
|
13
|
+
"@revideo/core": "0.4.5",
|
|
14
|
+
"@revideo/ffmpeg": "0.4.5",
|
|
15
|
+
"@revideo/renderer": "0.4.5",
|
|
16
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
17
17
|
"@sparticuz/chromium": "^123.0.1",
|
|
18
18
|
"aws-lambda": "^1.0.7",
|
|
19
19
|
"aws-sdk": "^2.1642.0",
|
|
20
20
|
"ffmpeg-static": "^5.2.0"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@revideo/cli": "^0.4.
|
|
24
|
-
"@revideo/ui": "0.4.
|
|
23
|
+
"@revideo/cli": "^0.4.5",
|
|
24
|
+
"@revideo/ui": "0.4.5",
|
|
25
25
|
"typescript": "^5.2.2",
|
|
26
26
|
"vite": "^4.5"
|
|
27
27
|
}
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "0.4.
|
|
13
|
-
"@revideo/2d": "0.4.
|
|
14
|
-
"@revideo/renderer": "0.4.
|
|
15
|
-
"@revideo/vite-plugin": "0.4.
|
|
16
|
-
"@revideo/ffmpeg": "0.4.
|
|
12
|
+
"@revideo/core": "0.4.5",
|
|
13
|
+
"@revideo/2d": "0.4.5",
|
|
14
|
+
"@revideo/renderer": "0.4.5",
|
|
15
|
+
"@revideo/vite-plugin": "0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "0.4.5"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "0.4.
|
|
20
|
-
"@revideo/cli": "0.4.
|
|
19
|
+
"@revideo/ui": "0.4.5",
|
|
20
|
+
"@revideo/cli": "0.4.5",
|
|
21
21
|
"typescript": "^5.2.2",
|
|
22
22
|
"vite": "^4.5"
|
|
23
23
|
}
|
|
@@ -9,14 +9,14 @@
|
|
|
9
9
|
"render": "tsc && node dist/render.js"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@revideo/core": "0.
|
|
13
|
-
"@revideo/2d": "0.
|
|
14
|
-
"@revideo/renderer": "0.
|
|
15
|
-
"@revideo/vite-plugin": "0.
|
|
16
|
-
"@revideo/ffmpeg": "0.
|
|
12
|
+
"@revideo/core": "0.4.4",
|
|
13
|
+
"@revideo/2d": "0.4.4",
|
|
14
|
+
"@revideo/renderer": "0.4.4",
|
|
15
|
+
"@revideo/vite-plugin": "0.4.4",
|
|
16
|
+
"@revideo/ffmpeg": "0.4.4"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"@revideo/ui": "0.
|
|
19
|
+
"@revideo/ui": "0.4.4",
|
|
20
20
|
"typescript": "^5.2.2",
|
|
21
21
|
"vite": "^4.5"
|
|
22
22
|
}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import {makeProject} from '@revideo/core';
|
|
2
|
-
|
|
3
2
|
import example from './scenes/example?scene';
|
|
4
3
|
|
|
5
4
|
export default makeProject({
|
|
@@ -15,11 +14,6 @@ export default makeProject({
|
|
|
15
14
|
src: "https://revideo-example-assets.s3.amazonaws.com/beach-2.mp4",
|
|
16
15
|
start: 2,
|
|
17
16
|
duration: 10
|
|
18
|
-
},
|
|
19
|
-
{
|
|
20
|
-
src: "https://revideo-example-assets.s3.amazonaws.com/beach-1.mp4",
|
|
21
|
-
start: 1,
|
|
22
|
-
duration: 7
|
|
23
17
|
}
|
|
24
18
|
]
|
|
25
19
|
}
|
|
@@ -1,56 +1,24 @@
|
|
|
1
1
|
import {renderVideo} from '@revideo/renderer';
|
|
2
2
|
|
|
3
|
-
const progressTracker = new Map<number, number>();
|
|
4
|
-
|
|
5
|
-
function trackProgress(id: number, progress: number) {
|
|
6
|
-
progressTracker.set(id, progress);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
function printProgress() {
|
|
10
|
-
let line = '';
|
|
11
|
-
for (const [key, value] of progressTracker.entries()) {
|
|
12
|
-
line += `${key}: ${(value * 100).toFixed(0)}% `;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
if (line === '') {
|
|
16
|
-
return;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
console.log(line);
|
|
20
|
-
}
|
|
21
|
-
|
|
22
3
|
async function render() {
|
|
23
4
|
console.log('Rendering video...');
|
|
24
|
-
|
|
25
|
-
const interval = setInterval(() => {
|
|
26
|
-
printProgress();
|
|
27
|
-
}, 1000);
|
|
28
|
-
|
|
29
5
|
// This is the main function that renders the video
|
|
30
|
-
const file = await renderVideo(
|
|
31
|
-
'./
|
|
32
|
-
{
|
|
6
|
+
const file = await renderVideo({
|
|
7
|
+
projectFile: './src/project.ts',
|
|
8
|
+
variables: {
|
|
33
9
|
videos: [
|
|
34
10
|
{
|
|
35
11
|
src: "https://revideo-example-assets.s3.amazonaws.com/beach-3.mp4",
|
|
36
|
-
start: 2,
|
|
37
|
-
duration: 5
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
src: "https://revideo-example-assets.s3.amazonaws.com/beach-2.mp4",
|
|
41
12
|
start: 1,
|
|
42
|
-
duration:
|
|
13
|
+
duration: 6
|
|
43
14
|
},
|
|
44
15
|
{
|
|
45
|
-
src: "https://revideo-example-assets.s3.amazonaws.com/beach-
|
|
46
|
-
start:
|
|
47
|
-
duration:
|
|
16
|
+
src: "https://revideo-example-assets.s3.amazonaws.com/beach-2.mp4",
|
|
17
|
+
start: 2,
|
|
18
|
+
duration: 10
|
|
48
19
|
}
|
|
49
|
-
]}
|
|
50
|
-
|
|
51
|
-
);
|
|
52
|
-
|
|
53
|
-
clearInterval(interval);
|
|
20
|
+
]}
|
|
21
|
+
});
|
|
54
22
|
|
|
55
23
|
console.log(`Rendered video to ${file}`);
|
|
56
24
|
}
|
|
@@ -10,19 +10,19 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@deepgram/sdk": "^3.3.1",
|
|
13
|
-
"@revideo/2d": "^0.
|
|
14
|
-
"@revideo/cli": "^0.
|
|
15
|
-
"@revideo/core": "^0.
|
|
16
|
-
"@revideo/ffmpeg": "^0.
|
|
17
|
-
"@revideo/renderer": "^0.
|
|
18
|
-
"@revideo/vite-plugin": "^0.
|
|
13
|
+
"@revideo/2d": "^0.4.5",
|
|
14
|
+
"@revideo/cli": "^0.4.5",
|
|
15
|
+
"@revideo/core": "^0.4.5",
|
|
16
|
+
"@revideo/ffmpeg": "^0.4.5",
|
|
17
|
+
"@revideo/renderer": "^0.4.5",
|
|
18
|
+
"@revideo/vite-plugin": "^0.4.5",
|
|
19
19
|
"dotenv": "^16.4.5",
|
|
20
20
|
"express": "^4.19.2",
|
|
21
21
|
"openai": "^4.40.2",
|
|
22
22
|
"uuid": "^9.0.1"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
|
-
"@revideo/ui": "^0.
|
|
25
|
+
"@revideo/ui": "^0.4.5",
|
|
26
26
|
"@types/uuid": "^9.0.8",
|
|
27
27
|
"typescript": "^5.2.2",
|
|
28
28
|
"vite": "^4.5"
|
|
@@ -33,7 +33,10 @@ async function createVideo(topic: string, voiceName: string){
|
|
|
33
33
|
await fs.promises.writeFile(`./public/${jobId}-metadata.json`, JSON.stringify(metadata, null, 2));
|
|
34
34
|
|
|
35
35
|
console.log("Assets generated! Rendering video...")
|
|
36
|
-
await renderVideo(
|
|
36
|
+
await renderVideo({
|
|
37
|
+
projectFile: './src/project.ts',
|
|
38
|
+
variables: metadata
|
|
39
|
+
});
|
|
37
40
|
console.log("Render finished");
|
|
38
41
|
}
|
|
39
42
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@revideo/create",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.6-alpha.1017+15390c33",
|
|
4
4
|
"description": "Quickly scaffold revideo projects",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"author": "revideo",
|
|
@@ -20,17 +20,17 @@
|
|
|
20
20
|
"url": "https://github.com/havenhq/revideo.git"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@revideo/2d": "0.4.
|
|
24
|
-
"@revideo/core": "0.4.
|
|
25
|
-
"@revideo/ffmpeg": "0.4.
|
|
26
|
-
"@revideo/renderer": "0.4.
|
|
27
|
-
"@revideo/ui": "0.4.
|
|
28
|
-
"@revideo/vite-plugin": "0.4.
|
|
23
|
+
"@revideo/2d": "^0.4.6-alpha.1017+15390c33",
|
|
24
|
+
"@revideo/core": "^0.4.6-alpha.1017+15390c33",
|
|
25
|
+
"@revideo/ffmpeg": "^0.4.6-alpha.1017+15390c33",
|
|
26
|
+
"@revideo/renderer": "^0.4.6-alpha.1017+15390c33",
|
|
27
|
+
"@revideo/ui": "^0.4.6-alpha.1017+15390c33",
|
|
28
|
+
"@revideo/vite-plugin": "^0.4.6-alpha.1017+15390c33"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@revideo/telemetry": "0.4.
|
|
31
|
+
"@revideo/telemetry": "^0.4.6-alpha.1017+15390c33",
|
|
32
32
|
"minimist": "^1.2.8",
|
|
33
33
|
"prompts": "^2.4.2"
|
|
34
34
|
},
|
|
35
|
-
"gitHead": "
|
|
35
|
+
"gitHead": "15390c33b019b663d594042ad03bdf6aea217c73"
|
|
36
36
|
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
FROM node:18-bullseye
|
|
2
|
-
|
|
3
|
-
RUN apt-get update && apt-get install -y \
|
|
4
|
-
nscd \
|
|
5
|
-
libnss3 \
|
|
6
|
-
libdbus-1-3 \
|
|
7
|
-
libatk1.0-0 \
|
|
8
|
-
libatk-bridge2.0-0 \
|
|
9
|
-
libcups2 \
|
|
10
|
-
libxkbcommon0 \
|
|
11
|
-
libxcomposite1 \
|
|
12
|
-
libxdamage1 \
|
|
13
|
-
libxrandr2 \
|
|
14
|
-
libgbm1 \
|
|
15
|
-
libpango-1.0-0 \
|
|
16
|
-
libcairo2 \
|
|
17
|
-
libasound2 \
|
|
18
|
-
libatspi2.0-0
|
|
19
|
-
|
|
20
|
-
RUN apt-get install -y libxfixes3
|
|
21
|
-
|
|
22
|
-
WORKDIR /usr/src/app
|
|
23
|
-
|
|
24
|
-
RUN wget https://github.com/eugeneware/ffmpeg-static/releases/download/b6.0/ffmpeg-linux-x64
|
|
25
|
-
|
|
26
|
-
RUN chmod +x ffmpeg-linux-x64
|
|
27
|
-
|
|
28
|
-
RUN mv ffmpeg-linux-x64 ffmpeg
|
|
29
|
-
|
|
30
|
-
RUN mv ffmpeg /usr/local/bin/
|
|
31
|
-
|
|
32
|
-
ENV FFMPEG_PATH=ffmpeg
|
|
33
|
-
|
|
34
|
-
RUN wget https://github.com/eugeneware/ffmpeg-static/releases/download/b6.0/ffprobe-linux-x64
|
|
35
|
-
|
|
36
|
-
RUN chmod +x ffprobe-linux-x64
|
|
37
|
-
|
|
38
|
-
RUN mv ffprobe-linux-x64 ffprobe
|
|
39
|
-
|
|
40
|
-
RUN mv ffprobe /usr/local/bin/
|
|
41
|
-
|
|
42
|
-
ENV FFPROBE_PATH=ffprobe
|
|
43
|
-
|
|
44
|
-
COPY package*.json ./
|
|
45
|
-
|
|
46
|
-
COPY . ./
|
|
47
|
-
|
|
48
|
-
RUN npm install
|
|
49
|
-
|
|
50
|
-
RUN npx puppeteer browsers install chrome
|
|
51
|
-
|
|
52
|
-
RUN apt-get update && apt-get install -y nscd libnss3
|
|
53
|
-
|
|
54
|
-
RUN ffmpeg -version
|
|
55
|
-
|
|
56
|
-
CMD service nscd start && npm run serve
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
# Revideo on Google Cloud Run
|
|
2
|
-
|
|
3
|
-
This is an example project demonstrating how you can deploy Revideo projects on Google Cloud Run for rendering.
|
|
4
|
-
|
|
5
|
-
The project is structured like a normal Revideo project, but it also contains a minimal Express server in `src/index.ts` that exposes a `/render` endpoint calling `renderVideo()` ([function docs](https://docs.re.video/renderer/renderVideo)). It also contains a Dockerfile that sets up an environment to run Revideo out of the box on Cloud Run.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
### Getting Started
|
|
9
|
-
|
|
10
|
-
To deploy the example proejct to Cloud Run, you should have a Google Cloud account and have enabled the [Cloud Run API](https://console.cloud.google.com/run). You should also install the gcloud CLI ([guide](https://cloud.google.com/sdk/docs/install)).
|
|
11
|
-
|
|
12
|
-
After cloning the `revideo-examples` project, navigate to `/google-cloud-run`. Now, you can run the following command to deploy the example project.
|
|
13
|
-
|
|
14
|
-
```
|
|
15
|
-
gcloud run deploy revideo-cloudrun-example --source . --region us-east1 --memory 8Gi --cpu 4 --allow-unauthenticated --concurrency=1
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
Once the function is deployed, you will receive a service URL in your terminal. You can run the following command to trigger a video render:
|
|
19
|
-
|
|
20
|
-
```
|
|
21
|
-
curl -X POST https://<your-service-url>/render \
|
|
22
|
-
-H "Content-Type: application/json" \
|
|
23
|
-
-d '{
|
|
24
|
-
"variables": {"username": "Sarah"}
|
|
25
|
-
}' --output output.mp4
|
|
26
|
-
```
|
|
27
|
-
|
|
28
|
-
This will save the file which is sent back as a response to `output.mp4`. In production, it would be better to upload the file to a bucket instead of sending it back as a response - here, we merely use this approach for simplicity - if you want to upload the result file to a bucket instead of sending it back, you can do so by modifying `src/index.ts`.
|
|
29
|
-
|
|
30
|
-
Note that `--concurrency=1` makes sure that every request will spin up a new container instance to render a video. This is intentional, as rendering is a computationally expensive process. If you want to, you can also try decreasing the requested cpu and memory - 8Gi and 4 cpu is more than sufficient. When deploying in production, you might also want to require authentication.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
### Deploying your own Video Template
|
|
34
|
-
|
|
35
|
-
If you want to deploy your own video template, you can simply change the code in `src/scenes/example.tsx` and redeploy the service by running the `gcloud run deploy` command from above.
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "google-cloud-run",
|
|
3
|
-
"private": true,
|
|
4
|
-
"version": "0.0.0",
|
|
5
|
-
"scripts": {
|
|
6
|
-
"start": "vite",
|
|
7
|
-
"serve": "tsc && node dist/index.js",
|
|
8
|
-
"build": "tsc && vite build",
|
|
9
|
-
"render": "tsc && node dist/render.js"
|
|
10
|
-
},
|
|
11
|
-
"dependencies": {
|
|
12
|
-
"@revideo/2d": "0.3.6",
|
|
13
|
-
"@revideo/core": "0.3.6",
|
|
14
|
-
"@revideo/ffmpeg": "0.3.6",
|
|
15
|
-
"@revideo/renderer": "0.3.6",
|
|
16
|
-
"@revideo/vite-plugin": "0.3.6",
|
|
17
|
-
"express": "^4.19.2",
|
|
18
|
-
"uuid": "^9.0.1"
|
|
19
|
-
},
|
|
20
|
-
"devDependencies": {
|
|
21
|
-
"@revideo/cli": "^0.3.6",
|
|
22
|
-
"@revideo/ui": "0.3.6",
|
|
23
|
-
"@types/express": "^4.17.21",
|
|
24
|
-
"@types/uuid": "^9.0.8",
|
|
25
|
-
"typescript": "^5.2.2",
|
|
26
|
-
"vite": "^4.5"
|
|
27
|
-
}
|
|
28
|
-
}
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { renderVideo } from '@revideo/renderer';
|
|
2
|
-
import { v4 as uuidv4 } from 'uuid';
|
|
3
|
-
import * as express from 'express';
|
|
4
|
-
import * as fs from 'fs';
|
|
5
|
-
import * as path from 'path';
|
|
6
|
-
|
|
7
|
-
const app = express();
|
|
8
|
-
app.use(express.json());
|
|
9
|
-
|
|
10
|
-
app.get('/', (req, res) => {
|
|
11
|
-
res.status(200).send(`Hello World!`);
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
app.post('/render', async (req, res) => {
|
|
15
|
-
try {
|
|
16
|
-
const { variables } = req.body;
|
|
17
|
-
const jobId = uuidv4();
|
|
18
|
-
|
|
19
|
-
console.log("Rendering video...")
|
|
20
|
-
await renderVideo("./vite.config.ts", variables, () => {}, { name: jobId, logProgress: true, puppeteer: { args: ['--no-sandbox', '--disable-setuid-sandbox'] }});
|
|
21
|
-
console.log("Finished rendering")
|
|
22
|
-
|
|
23
|
-
const outputFilePath = path.join(process.cwd(), `./output/${jobId}.mp4`);
|
|
24
|
-
|
|
25
|
-
if (fs.existsSync(outputFilePath)) {
|
|
26
|
-
res.sendFile(outputFilePath); // alternatively (and recommended), upload file to a bucket
|
|
27
|
-
} else {
|
|
28
|
-
res.status(500).send('Rendered video not found');
|
|
29
|
-
}
|
|
30
|
-
} catch (err) {
|
|
31
|
-
console.error('Error rendering video:', err);
|
|
32
|
-
res.status(500).send('Error rendering video');
|
|
33
|
-
}
|
|
34
|
-
});
|
|
35
|
-
|
|
36
|
-
const port = parseInt(process.env.PORT) || 8080;
|
|
37
|
-
app.listen(port, () => {
|
|
38
|
-
console.log(`listening on port ${port}`);
|
|
39
|
-
});
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 0,
|
|
3
|
-
"shared": {
|
|
4
|
-
"background": null,
|
|
5
|
-
"range": [
|
|
6
|
-
0,
|
|
7
|
-
null
|
|
8
|
-
],
|
|
9
|
-
"size": {
|
|
10
|
-
"x": 1920,
|
|
11
|
-
"y": 1080
|
|
12
|
-
},
|
|
13
|
-
"audioOffset": 0
|
|
14
|
-
},
|
|
15
|
-
"preview": {
|
|
16
|
-
"fps": 30,
|
|
17
|
-
"resolutionScale": 1
|
|
18
|
-
},
|
|
19
|
-
"rendering": {
|
|
20
|
-
"fps": 30,
|
|
21
|
-
"resolutionScale": 1,
|
|
22
|
-
"colorSpace": "srgb",
|
|
23
|
-
"exporter": {
|
|
24
|
-
"name": "@revideo/core/ffmpeg",
|
|
25
|
-
"options": {
|
|
26
|
-
"fastStart": true,
|
|
27
|
-
"includeAudio": true
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
/// <reference types="@revideo/core/project" />
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import {Audio, Txt, Video, makeScene2D} from '@revideo/2d';
|
|
2
|
-
import {all, chain, createRef, waitFor, useScene} from '@revideo/core';
|
|
3
|
-
|
|
4
|
-
export default makeScene2D(function* (view) {
|
|
5
|
-
const textRef = createRef<Txt>();
|
|
6
|
-
|
|
7
|
-
yield view.add(
|
|
8
|
-
<>
|
|
9
|
-
<Video
|
|
10
|
-
src={'https://revideo-example-assets.s3.amazonaws.com/stars.mp4'}
|
|
11
|
-
size={['100%', '100%']}
|
|
12
|
-
play={true}
|
|
13
|
-
/>
|
|
14
|
-
<Audio
|
|
15
|
-
src={'https://revideo-example-assets.s3.amazonaws.com/chill-beat.mp3'}
|
|
16
|
-
play={true}
|
|
17
|
-
time={17.0}
|
|
18
|
-
/>
|
|
19
|
-
</>,
|
|
20
|
-
);
|
|
21
|
-
|
|
22
|
-
yield* waitFor(1);
|
|
23
|
-
|
|
24
|
-
view.add(
|
|
25
|
-
<Txt fontFamily={"Sans-Serif"} fill={"white"} fontSize={10} ref={textRef}>Hello {useScene().variables.get("username", "user")()}</Txt>
|
|
26
|
-
);
|
|
27
|
-
|
|
28
|
-
yield* textRef().scale(10, 1);
|
|
29
|
-
yield* waitFor(2);
|
|
30
|
-
});
|