@remotion/media 4.0.410 → 4.0.412
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/dist/esm/index.mjs
CHANGED
|
@@ -3406,7 +3406,8 @@ var extractFrameInternal = async ({
|
|
|
3406
3406
|
if (timeInSeconds === null) {
|
|
3407
3407
|
return {
|
|
3408
3408
|
type: "success",
|
|
3409
|
-
|
|
3409
|
+
frame: null,
|
|
3410
|
+
rotation: 0,
|
|
3410
3411
|
durationInSeconds: await sink.getDuration()
|
|
3411
3412
|
};
|
|
3412
3413
|
}
|
|
@@ -3421,14 +3422,17 @@ var extractFrameInternal = async ({
|
|
|
3421
3422
|
if (!keyframeBank) {
|
|
3422
3423
|
return {
|
|
3423
3424
|
type: "success",
|
|
3424
|
-
|
|
3425
|
+
frame: null,
|
|
3426
|
+
rotation: 0,
|
|
3425
3427
|
durationInSeconds: await sink.getDuration()
|
|
3426
3428
|
};
|
|
3427
3429
|
}
|
|
3428
3430
|
const frame = await keyframeBank.getFrameFromTimestamp(timeInSeconds);
|
|
3431
|
+
const rotation = frame?.rotation ?? 0;
|
|
3429
3432
|
return {
|
|
3430
3433
|
type: "success",
|
|
3431
|
-
|
|
3434
|
+
frame: frame?.toVideoFrame() ?? null,
|
|
3435
|
+
rotation,
|
|
3432
3436
|
durationInSeconds: await sink.getDuration()
|
|
3433
3437
|
};
|
|
3434
3438
|
} catch (err) {
|
|
@@ -3550,9 +3554,9 @@ var extractFrameAndAudio = async ({
|
|
|
3550
3554
|
}
|
|
3551
3555
|
return {
|
|
3552
3556
|
type: "success",
|
|
3553
|
-
frame: video?.
|
|
3554
|
-
frame: video.
|
|
3555
|
-
rotation: video.
|
|
3557
|
+
frame: video?.frame ? await rotateFrame({
|
|
3558
|
+
frame: video.frame,
|
|
3559
|
+
rotation: video.rotation
|
|
3556
3560
|
}) : null,
|
|
3557
3561
|
audio: audio?.data ?? null,
|
|
3558
3562
|
durationInSeconds: audio?.durationInSeconds ?? null
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type { VideoSample } from 'mediabunny';
|
|
2
1
|
import { type LogLevel } from 'remotion';
|
|
3
2
|
type ExtractFrameResult = {
|
|
4
3
|
type: 'success';
|
|
5
|
-
|
|
4
|
+
frame: VideoFrame | null;
|
|
5
|
+
rotation: number;
|
|
6
6
|
durationInSeconds: number | null;
|
|
7
7
|
} | {
|
|
8
8
|
type: 'cannot-decode';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remotion/media",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.412",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"module": "dist/esm/index.mjs",
|
|
@@ -23,14 +23,14 @@
|
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"mediabunny": "1.29.0",
|
|
26
|
-
"remotion": "4.0.
|
|
26
|
+
"remotion": "4.0.412"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"react": ">=16.8.0",
|
|
30
30
|
"react-dom": ">=16.8.0"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
33
|
+
"@remotion/eslint-config-internal": "4.0.412",
|
|
34
34
|
"@vitest/browser-webdriverio": "4.0.9",
|
|
35
35
|
"eslint": "9.19.0",
|
|
36
36
|
"react": "19.2.3",
|